Mercurial > evolve
diff src/topic/revset.py @ 1864:70d1191fceed
topic: allow use of topic(.) to match the p1 topic
As far as I can tell this matches the behavior of branch(.) in core hg
in tht it matches p1's value rather than the wdir value.
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Wed, 30 Sep 2015 18:06:42 -0400 |
parents | 24d8053020a2 |
children | 558dd43b599d |
line wrap: on
line diff
--- a/src/topic/revset.py Wed Sep 30 18:05:27 2015 -0400 +++ b/src/topic/revset.py Wed Sep 30 18:06:42 2015 -0400 @@ -15,6 +15,8 @@ if args: # match a specific topic topic = revset.getstring(args[0], 'topic() argument must be a string') + if topic == '.': + topic = repo['.'].extra().get('topic', '') _kind, _pattern, matcher = revset._stringmatcher(topic) else: matcher = lambda t: bool(t)