Mercurial > evolve
diff src/topic/__init__.py @ 1857:a506ed8ab8da
topics: add listnames hook so completion works
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Mon, 15 Jun 2015 16:56:44 -0500 |
parents | 7d7f5f9e2f8c |
children | 4ab1b854ce4e |
line wrap: on
line diff
--- a/src/topic/__init__.py Thu Jun 18 15:46:26 2015 -0400 +++ b/src/topic/__init__.py Mon Jun 15 16:56:44 2015 -0500 @@ -63,10 +63,11 @@ def currenttopic(self): return self.vfs.tryread('topic') + repo.__class__ = topicrepo if util.safehasattr(repo, 'names'): repo.names.addnamespace(namespaces.namespace( - 'topics', 'topic', namemap=_namemap, nodemap=_nodemap)) - repo.__class__ = topicrepo + 'topics', 'topic', namemap=_namemap, nodemap=_nodemap, + listnames=lambda repo: repo.topics)) @command('topics [TOPIC]', [ ('', 'clear', False, 'clear active topic if any'),