• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tutorial on Eclipse Launch Configuration?

 
Tong Wang
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everyone,

I am new to Eclipse 3.3 (having been using JBoss Eclipse). While playing with the hibernate4gwt sample project, I noticed a launch configration file with the ".launch" file name suffix:



I wonder if someone could help me understand this or point me to some documents.

Thanks,
Tong

(Escaped the XML to make it visible - PC)
[ December 11, 2007: Message edited by: Paul Clapham ]
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34870
369
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tong,
The Eclipse help probably explains this.

While you can view the .launch file in a text editor, it is more interesting and intuitive to look at it differently. If you go to the Run menu and choose "Run as", you can view the launch configuration. It shows a nice wizard with all the options.

The .launch file is the stored settings, so you can run the same launch configuration in the future or share it with others.
 
Tong Wang
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I see, thank you.

Also, in JBoss Eclipse, for each project, you can configure how the file will be packaged: what go into a WAR, what go into a JAR, etc. Eclipse 3.3 doesn't seem to have this option. So, to produce a EAR for deployment, do I have to use some external build tool, like Ant or Maven?
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34870
369
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tong,
Eclipse doesn't explicitly support J2EE. You need to download a J2EE plugin or better yet use an Ant/Maven script.
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18281
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Aha! So that's where they hide that stuff!

That's a config file used by the Eclipse Run and Debug functions and it defines the run/debug environment for an Eclipse run unit - which can be a webapp test, stand-alone application, junit test(s) or certain other things, such as Maven builds.

Those files are normally kept in the workspace .metadata directory and should therefore be, in effect, invisible. Every Eclipse workspace for every eclipse user should be a distinct entity and not shared or stored under version control, so you should normally never know that they exist, to say nothing of what's in them.

Then again, it can be really annoying when you have a complex test environment and want to move the project to another machine. There's no way to export that stuff via the Eclipse IDE that I know of. So it's possible that some clever person took advantage of some inside knowledge and manually made a copy of it.

Although, because it's not an "official" Eclipse file format, use it with care.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic