navaneeth.suresh created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers.
REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5475 AFFECTED FILES mercurial/commands.py CHANGE DETAILS diff --git a/mercurial/commands.py b/mercurial/commands.py --- a/mercurial/commands.py +++ b/mercurial/commands.py @@ -1054,6 +1054,7 @@ _('set branch name even if it shadows an existing branch')), ('C', 'clean', None, _('reset branch name to parent branch name')), ('r', 'rev', [], _('change branches of the given revs (EXPERIMENTAL)')), + ('s', 'show', None, _('show branch name of the given rev')) ], _('[-fC] [NAME]'), helpcategory=command.CATEGORY_CHANGE_ORGANIZATION) @@ -1097,6 +1098,11 @@ ui.write("%s\n" % repo.dirstate.branch()) return + elif opts.get('show') and label: + ctx = scmutil.revsingle(repo, label) + ui.write("%s\n" % ctx.branch()) + return + with repo.wlock(): if opts.get('clean'): label = repo[None].p1().branch() To: navaneeth.suresh, #hg-reviewers Cc: mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel