D1074: branch: add a --rev flag to change branch name of given revisions
lothiraldan (Boris Feld)
phabricator at mercurial-scm.org
Tue Jan 16 15:15:56 EST 2018
lothiraldan added a comment.
Apart from my review, it looks good to me.
Also I don't think you have a test when trying to change the branch of several changesets on different branches. If not, could you add one?
INLINE COMMENTS
> cmdutil.py:731
> + if repo.revs('merge() and %ld', revs):
> + raise error.Abort(_("cannot change branch of a merge commit"))
> + if repo.revs('obsolete() and %ld', revs):
Might be helpful to precise which changeset is a merge commit.
> cmdutil.py:733
> + if repo.revs('obsolete() and %ld', revs):
> + raise error.Abort(_("cannot change branch of a obsolete changeset"))
> + heads = repo.revs('head() and %ld', revs)
Might be helpful to precise which changeset is am obsolete commit.
> test-branch-change.t:143
> + $ hg bookmark b1
> + $ hg glog -r .
> + @ 6:7c1991464886 Added e
You should update the revset to use the same as the next glog call `(.^)::`
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D1074
To: pulkit, #hg-reviewers, dlax, ryanmce
Cc: durin42, krbullock, yuja, indygreg, lothiraldan, ryanmce, dlax, mercurial-devel
More information about the Mercurial-devel
mailing list