I have a mercurial repository with numerous branches for stable, development, experimental features etc. However, I've found a bug in a set of core application files that are common to each branch.

Is there a way to modify these files, and then push the changes to the common files to all the other branches, without sending any other changes?


The ideal way is to make the changes on the most stable branch, and then merge the change into the other branches. If you can, you should aim to have a hierarchy of branches so that stable is a subset of development, which is a subset of experimental.

That means that you will always pull from stable into development, and from development into experimental. This way you wont forget to propagate a bugfix, you just always pull and merge.

However, people do forget to put the bugfixes on the right branch from time to time. It also happens that a bugfix is upgraded in severity after it was put on development, say, and now you need it on stable as well.

The transplant extension is there to help you with that. You use it to copy a change from one place to another. Please see my recent tutorial on tast based development for nice screenshots and a walk-through.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.