Mercurial > public > mercurial-scm > hg
diff mercurial/discovery.py @ 21580:32601b0b74c0
discovery: if a push would create a new head, mention the bookmark name if any
author | Stephen Lee <sphen.lee@gmail.com> |
---|---|
date | Sat, 08 Mar 2014 19:02:39 +1100 |
parents | 56a04085c23c |
children | 70383c6961b4 |
line wrap: on
line diff
--- a/mercurial/discovery.py Wed May 14 10:38:05 2014 -0700 +++ b/mercurial/discovery.py Sat Mar 08 19:02:39 2014 +1100 @@ -341,6 +341,10 @@ if branch not in ('default', None): error = _("push creates new remote head %s " "on branch '%s'!") % (short(dhs[0]), branch) + elif repo[dhs[0]].bookmarks(): + error = _("push creates new remote head %s " + "with bookmark '%s'!") % ( + short(dhs[0]), repo[dhs[0]].bookmarks()[0]) else: error = _("push creates new remote head %s!" ) % short(dhs[0])