Eclipse - how to use it in a team environment

Associate
Joined
19 Jun 2003
Posts
1,680
Location
West Yorks, UK
Hi,
I've been trying out Eclipse PDT for PHP development at work. The setup is like this:


I've been trying to work out how both developers can use Eclipse, but work from the same network share (ie., the webroot of the Development Server's VirtualHost). Is it possible to create a Project in Eclipse that both of us can access and work with, or should we have Apache running on our own PC's, and work separately, checking our changes into Subversion, and then updating the main Development Server every so often.

What's the normal way it is done with Eclipse? Can we both work from the same set of files, to save me setting up Apache etc on both PC's, and having 3 copies of the same files in 3 different locations?

Cheers,
Mattt
 
Hi Matt,

I think you'd be wanting to use something like IBM Clearcase with the Eclipse plugin for this type of work. I'm no expert in the area though, so hopefully you'll get a more informed opinion
 
Hi,
Thanks for your reply. I'm sure i'm not asking anything unusual, and i'm sure Eclipse can do it. I presume bigger companies using Eclipse don't have their developers working off their individual computers, but have them working on the same Server.

Can anyone else give any insight into it?

Matt
 
What's the rationale for both working on the same development server and having commits coming from the same code? You should have a solution that allows you to manage which code introduced bugs, do formal testing/QA on and not step on each others toes if you're working in the same area. What happens if one of you writes some code that completely breaks your app? You don't want to be sitting around waiting for them to fix it. What happens when you have 5, 10, 15 or more developers working on the code making lots and lots of changes continually? You can't have multiple people working on the same file in a filesystem at the same time - there's no way to sensibly and safely merge those changes.

Ideally you should each have your own sandbox - a checkout of the codebase and a server setup equivalent to the production architecture. I can't imagine many companies have developers working directly on test/production servers with the same files - it's not scalable. Commit and update in small increments so you avoid conflicts and can easily track/revert changes in the codebase. The IDE you use shouldn't be a factor in the development process.

If you're working on the same server because of deployment issues, then it would be wise to look at a proper automated process. With PHP it's a bit tricky because there's no build process to run, but you can use a post-commit hook to push the latest code to the test server - http://subversion.tigris.org/faq.html#website-auto-update.
 
Use one of the subversion plugins for Eclipse (I prefer Subclipse over Subversive - seems to throw less errors and be a bit more robust for me), it hooks into the team system and would allow you both to make changes/check them in etc.
 
Was gonna say, your developers should be individually developing from their own machines and making commits to a branch in subversion.

The development server is really only for a database.
 
Thanks for the replies - seems i'm approaching it the wrong way then.

I will look into setting up a mini-dev environment for each developer, and commit the changes to the central server for final testing before deployment.

Cheers,
Matt
 
Back
Top Bottom