selectively applying changesets

Michael Paesold mpaesold at gmx.at
Thu Sep 29 01:58:23 CDT 2005


Jan Hudec wrote:
> Also the head marking plays better with pull/push -r, because pull/push
> without -r is just pull/push all exported heads. And what I expect to be
> common use-case is to have private branch to work on and a public one, and
> upon reaching reasonable state, simply doing "hg push -r tip public". No
> caring about the exported/non-exported flags and all that...

I think having pull/push and clone -r is good idea. It enables you to 
clone a repo only up to a certain changeset and trash any later work 
afterwards. The following development workflow would be possible:

hg clone main feature1 # clone main repo for new feature
hack ... hack ...  in feature1/, commit as needed

After some time, you recognize that you have gone a wrong way, but the 
initial work is good, you figure out which revision is still "good", 
than do:
hg clone -r a4d830edc742 feature1 feature1-next-attempt
and go on with the feature1-next repo. You can delete feature1 or keep 
it for reference.

Finally, when you think you're done you can push to the main repo.
For each feature you create your own branch.

This avoids having "bad" changesets in the main repo at all.

Best Regards,
Michael Paesold


More information about the Mercurial mailing list