[Updated] D9638: clone: update to active bookmark, if set
Phabricator
phabricator at mercurial-scm.org
Sat Jan 9 11:12:44 UTC 2021
Closed by commit rHG72007a9ac064: clone: update to active bookmark, if set (authored by Dan Villiom Podlaski Christiansen <danchr at gmail.com>).
This revision was automatically updated to reflect the committed changes.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D9638?vs=24445&id=24687
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D9638/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D9638
AFFECTED FILES
mercurial/hg.py
CHANGE DETAILS
diff --git a/mercurial/hg.py b/mercurial/hg.py
--- a/mercurial/hg.py
+++ b/mercurial/hg.py
@@ -1013,15 +1013,19 @@
pass
if uprev is None:
try:
- uprev = destrepo._bookmarks[b'@']
- update = b'@'
+ if destrepo._activebookmark:
+ uprev = destrepo.lookup(destrepo._activebookmark)
+ update = destrepo._activebookmark
+ else:
+ uprev = destrepo._bookmarks[b'@']
+ update = b'@'
bn = destrepo[uprev].branch()
if bn == b'default':
- status = _(b"updating to bookmark @\n")
+ status = _(b"updating to bookmark %s\n" % update)
else:
status = (
- _(b"updating to bookmark @ on branch %s\n") % bn
- )
+ _(b"updating to bookmark %s on branch %s\n")
+ ) % (update, bn)
except KeyError:
try:
uprev = destrepo.branchtip(b'default')
To: danchr, #hg-reviewers, pulkit, marmoute
Cc: marmoute, mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20210109/d6c2dca8/attachment-0002.html>
More information about the Mercurial-patches
mailing list