Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / January 2007

Tip: Looking for answers? Try searching our database.

question on eclipse and source control

Thread view: 
Christopher Corbell - 30 Jan 2007 19:09 GMT
Just curious since there was a discussion today on my team...

If you're using eclipse on a project do you check-in your project
files to source control for everyone to use?  (The .classpath
and .project files, that is).  Or do engineers just set up their own
local eclipse projects which are never checked-in?  What's the more
common approach?

TIA,
Chris
Corona4456 - 30 Jan 2007 20:14 GMT
On Jan 30, 12:09 pm, "Christopher Corbell" <chriscorb...@gmail.com>
wrote:
> Just curious since there was a discussion today on my team...
>
[quoted text clipped - 6 lines]
> TIA,
> Chris

IMO it would depend on whether there is a consensus on each team
member's configuration.  More importantly using the same IDE is a good
reason to add the .classpath and .project files.  This will help when
adding libraries and what not to your project. That way others don't
have to worry about that, although you can just as easily add it in
Eclipse :).  Right now I have a project in version control with those
files included and I haven't really run across a problem.  So whether
you put it in version control or not will not really affect you or
your team all that much.  So basically it's just a preference if you
ask me.
Jason Cavett - 30 Jan 2007 21:13 GMT
On Jan 30, 2:09 pm, "Christopher Corbell" <chriscorb...@gmail.com>
wrote:
> Just curious since there was a discussion today on my team...
>
[quoted text clipped - 6 lines]
> TIA,
> Chris

Since my teams have always used the same IDE (Eclipse), I always add
the .project and .classpath files to source control.  There are some
issues that may need to be worked out (AKA - don't add C:\your\local
\directory\whatever.jar to the classpath - use a variable so it is the
same across all Eclipse configurations) but generally it works out
pretty well.
Daniel Dyer - 30 Jan 2007 23:55 GMT
> Just curious since there was a discussion today on my team...
>
[quoted text clipped - 3 lines]
> local eclipse projects which are never checked-in?  What's the more
> common approach?

I don't use Eclipse, but the same issue is relevant to other IDEs.  I used  
to advocate excluding all IDE configuration from source control (with  
ignore patterns set to avoid accidental addition) and leaving it to  
individual developers' preferences.  The reasoning behind this is that  
they are often using different IDEs, usually have different personal  
preferences, and the IDE configuration is largely incidental since  
everybody must use the Ant build.xml for building (allowing different team  
members to use different tools/configurations for builds is  
counter-productive).

However, I'm now favouring maybe adding at least some of the configuration  
files to source control.

While we do have Eclipse users in the company, all of the Java developers  
on my current project team use IntelliJ IDEA.  IDEA uses three files for  
configuration - .ipr is the project file, .iml is the module file  
(typically more than one of these) and .iws is the workspace file.  I have  
added the .ipr and .iml files to Subversion and excluded the .iws file.  
This gives us shared configuration for paths, dependencies, etc. but  
leaves out developer-specific stuff like debug configurations and view  
settings.

IDEA is flexible as to where the configuration files reside, so in our  
case these shared ones are tucked away in a configuration directory in the  
project repository for team members to use if they wish.  This means they  
won't clash with files in the project root if the developer chooses to use  
their own configuration files.  A default configuration for NetBeans could  
easily be added to this configuration directory if needed and, assuming  
Eclipse is not too fussy about the location of its config files, you could  
do the same for Eclipse.

The advantage of using the shared files is that you get the benefit of any  
reconfigurations that other people do (for example, when a library  
dependency changes).  Another benefit is that if a new developer joins the  
team, they can get started straight away without having to set everything  
up for themselves.

Dan.

Signature

Daniel Dyer
https://watchmaker.dev.java.net - Evolutionary Algorithm Framework for Java



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.