[RFC] New core command: graft

Antoine Pitrou solipsis at pitrou.net
Mon Oct 10 14:40:56 CDT 2011

On Mon, 10 Oct 2011 13:42:56 -0500
Matt Mackall <mpm at selenic.com> wrote:
> > 
> > Like for merges, something like:
> > 
> > $ hg graft 81380082d216
> > 3 files updated, 0 files unrevolved, remember to commit.
> This was already in my example, so the real question is "how do we find
> out we're in the middle of a graft AFTER that?"

Well, I don't understand the concern. If you've just made a graft, why
would you forget about it? And is it important that the user be
reminded at every step?
"hg summary" would be a good place to display additional information,
but I don't think commands like "hg status" or "hg diff" need to be

> The questions is how do we add this new feature without rewriting
> everything. We don't want to add new logic to just about every other
> command and extension so that it now interacts properly with a graft,
> which is where this snowball of yours is going.

I guess there's a tension between providing a light-weight command
that doesn't touch the rest of the core (like "hg transplant") and
something more sophisticated that addresses the use cases of a larger
base of people.

But other features such as named branches are now everywhere too, not
just in "hg branch" and "hg branches".



More information about the Mercurial-devel mailing list