A Guide to Branching in Mercurial

Alexander Schatten ml_alexanderschatten at gmx.at
Sat Sep 5 04:38:03 CDT 2009


Martin, 

thanks for your detailed answer; this was also my understanding. I just think, that this is a significant issue of this blog-post.


May I add one question here, though, that I was already struggling with and that is in my opinion related. Assume this situation:


(1) I have a piece of Code version controlled and I am, say, at Rev. 10. Everything is fine so far.

(2) Now I continue a "risky" feature development, say until Rev. 15. Then I figure this leads nowhere, I have broken the system, whatever. 

(3) Hence I go back to rev. 10 (hg update 10). This was the last stable version. Then I continue working from here (Rev. 16, 17, ...). In effect I made a branche. This is why I have SCM, right?

Now: the thing is: this unnamed branch Rev. 11-15 will allways annoy me in the future, because I cannot push and I definitly do not want to merge crappy code into my main line of dev. 

What should be done in such a situation? Name the crappy branch? But then I have 100 names for each crappy side-stream that distract me? Is it possiblelto "end" such an unnamed branch, like "set it deprecated" so that it is not named, but not interfering any longer? 


Am I making myself clear?


thanks again for your detailed clearifications



Alex


More information about the Mercurial mailing list