Mercurial > public > mercurial-scm > hg-stable
diff mercurial/commands.py @ 33025:4b81776baa7a
commands: move activebookmarklabel to bookmarks module
This is going to be used in an upcoming patch that moves more methods to
bookmarks.py.
author | Sean Farley <sean@farley.io> |
---|---|
date | Tue, 20 Jun 2017 15:56:29 -0700 |
parents | ac57603a44fe |
children | f5f4c72de71a |
line wrap: on
line diff
--- a/mercurial/commands.py Tue Jun 20 15:36:43 2017 -0700 +++ b/mercurial/commands.py Tue Jun 20 15:56:29 2017 -0700 @@ -66,12 +66,6 @@ command = registrar.command(table) -# label constants -# until 3.5, bookmarks.current was the advertised name, not -# bookmarks.active, so we must use both to avoid breaking old -# custom styles -activebookmarklabel = 'bookmarks.active bookmarks.current' - # common command options globalopts = [ @@ -994,7 +988,7 @@ for bmark, n in sorted(marks.iteritems()): active = repo._activebookmark if bmark == active: - prefix, label = '*', activebookmarklabel + prefix, label = '*', bookmarks.activebookmarklabel else: prefix, label = ' ', '' @@ -4816,10 +4810,10 @@ ui.write(_('bookmarks:'), label='log.bookmark') if active is not None: if active in marks: - ui.write(' *' + active, label=activebookmarklabel) + ui.write(' *' + active, label=bookmarks.activebookmarklabel) marks.remove(active) else: - ui.write(' [%s]' % active, label=activebookmarklabel) + ui.write(' [%s]' % active, label=bookmarks.activebookmarklabel) for m in marks: ui.write(' ' + m, label='log.bookmark') ui.write('\n', label='log.bookmark')