… I will learn to not, under any circumstances, commit any code to the trunk which is not ready for immediate deployment.
Because when I do, I inevitably do “just a quick deploy to fix up that unrelated mistake” and then, boom, the lightbox on the front page silently fails for three days.
SIGH.
On the plus side, I once again have experimental confirmation that functional lightboxes beat the stuffing out of direct links to images!
It’s really easy to get into the habit of working out of the trunk. On my main product it was easy to create a 1.0 release branch and work off of that (since I haven’t released yet). On really small things — like the app I just released — I find it’s too much overhead and tend work out of the trunk.
Though I’ll admit things are going to get a little messy since I started Google Gears integration and decided to kill it. Now I have to merge all changes from the small app into my main product *before* the Google Gears stuff.
Ironically, branches are your friend even more when you’re working by yourself or a teeny group than when there’s lots of people.
The only real excuse not to use branches (in modern version control where branches are fast and cheap) is that merging is difficult when there’s 100 of them running in different directions.
The smaller the group, the less of a concern it is!
Idea: Run your dev branch on your production server as well, just on a different domain and a different database. That way you can “deploy” but still have time to mess with it and notice the strange error in the morning.
Get some automated Selenium tests!