Mercurial > public > mercurial-scm > hg-stable
diff mercurial/commands.py @ 25367:d0f1d8b4de57
pull: only list remote bookmarks if -B is used to populate pulled heads
Listing remote bookmarks results in network traffic and latency. This
should be avoided when possible.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Thu, 28 May 2015 13:55:03 -0700 |
parents | 62da2d7745f9 |
children | ae38370fe282 |
line wrap: on
line diff
--- a/mercurial/commands.py Sat May 30 12:46:30 2015 +0900 +++ b/mercurial/commands.py Thu May 28 13:55:03 2015 -0700 @@ -5119,11 +5119,11 @@ revs, checkout = hg.addbranchrevs(repo, other, branches, opts.get('rev')) - remotebookmarks = other.listkeys('bookmarks') if opts.get('bookmark'): if not revs: revs = [] + remotebookmarks = other.listkeys('bookmarks') for b in opts['bookmark']: if b not in remotebookmarks: raise util.Abort(_('remote bookmark %s not found!') % b)