I use subversion for this and it works well.
Usually I turn around until I have something cleaned up for release.
At this point, I will create a branch with a name like release. I will jump onto the production system and check out my newly created branch. For several projects, I will have an intermediate area that works on the production system.
For example, I might have a directory tree that looks like this:
/web/sites/release-1 /web/sites/release-2 /web/sites/release-3 /web/sites/release-4 /web/sites/stage ==> release-4 /web/sites/live ==> release-3
"stage" and "live" are symbolic links, and this is what Apache has for DocumentRoot for the virtual hosts www.example.com and stage.example.com)
This setting allows me to thoroughly test things in a real production environment, and then cut them by exchanging symbolic links.
Branching out before deployment, I can make disaster fixes during production in the rare case that I need to do this. Then I can combine these changes back into the trunk when it is convenient and appropriate.
Last tip: if you use working copies of subversion projects in a production environment, you need to ensure that apache does not allow users to browse .svn directories in your project:
in httpd.conf:
<Directory ~ "\.svn"> Order allow,deny Deny from all </Directory>
timdev
source share