Search code examples
phpsvnversion-controlcvs

Version control PHP Web Project


We have a PHP project that we would like to version control. Right now there are three of us working on a development version of the project which resides in an external folder to which all of our Eclipse IDEs are linked, and thus no version control.

What is the right way and the best way to version control this?

We have an SVN set up, but we just need to find a good way to check in and out that allows us to test on the development server. Any ideas?


Solution

  • We were in a similar situation, and here's what we ended up doing:

    • Set up two branches -- the release and development branch.
    • For the development branch, include a post-commit hook that deploys the repository to the dev server, so you can test.
    • Once you're ready, you merge your changes into the release branch. I'd also suggest putting in a post-commit hook for deployment there.

    You can also set up individual development servers for each of the team members, on their workstations. I find that it speeds things up a bit, although you do have some more setup time.

    We had to use a single development server, because we were using a proprietary CMS and ran into licensing issues. So our post-commit hook was a simple FTP bot.