« links for 2007-10-02 | Main | links for 2007-10-03 »

Quicksilver

I was spiking some changes to code today and yesterday, but didn't want to check them in until I was sure I had evolved the code to right place. I could have set up a dev branch, but it seemed much handier to init a mercurial repository locally and use that. So I gave it a try. It turned out after some work I had a stable revision to check in centrally, but I had committed beyond that in mercurial locally. What to do that get back to that revision and check into the source tree? To revert to a particular revision r123 when you are at r567 in mercurial is a regular update operation

hg update -r123

That rolls the code forward to revision 123, (that could be a tag also). That revision got checked in to central version control, and afterwards I rolled forward again to 567, which will need a review before committing.

It occurred to me that by setting up a local hg, I had in fact branched, but without the overhead and ceremony associated with branches. Driving the cost of branches to zero is transformational.

I've also had a good experience recently with using mercurial to version a code deploy that required some configuration post-deployment. This worked out well in two ways 1) checking in all config mods made on the server to bring back to central version control thus saying goodbye to .BAK files, 2) serving out the modified codebase using "hg serve" so other nodes in the cluster can get the changes, thus saying good bye to scp. More on that another time.


October 2, 2007 11:01 PM