changeset 5604:f27ef537bf83

branching: merge with stable
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Tue, 20 Oct 2020 10:33:46 +0200
parents 3946ee4ee3ae (current diff) 5e71952c8b4a (diff)
children af1d71f3a028
files hgext3rd/topic/revset.py
diffstat 2 files changed, 8 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/hgext3rd/topic/revset.py	Wed Oct 14 15:48:37 2020 +0200
+++ b/hgext3rd/topic/revset.py	Tue Oct 20 10:33:46 2020 +0200
@@ -76,7 +76,7 @@
 
 @revsetpredicate(b'ngtip([branch])')
 def ngtipset(repo, subset, x):
-    """The untopiced tip.
+    """The tip of a branch, ignoring changesets with a topic.
 
     Name is horrible so that people change it.
     """
@@ -85,7 +85,9 @@
     branch = revset.getstring(args[0], b'ngtip requires a string')
     if branch == b'.':
         branch = repo[b'.'].branch()
-    return subset & revset.baseset(destination.ngtip(repo, branch))
+    # list of length 1
+    revs = [repo[node].rev() for node in destination.ngtip(repo, branch)]
+    return subset & revset.baseset(revs)
 
 @revsetpredicate(b'stack()')
 def stackset(repo, subset, x):
--- a/tests/test-topic-dest.t	Wed Oct 14 15:48:37 2020 +0200
+++ b/tests/test-topic-dest.t	Tue Oct 20 10:33:46 2020 +0200
@@ -42,8 +42,10 @@
   |
   o  0 () c_alpha
   
-  $ hg log -r 'ngtip(.)'
-  3 () c_delta
+  $ hg log -G -r 'ngtip(.)'
+  o  3 () c_delta
+  |
+  ~
   $ hg log -r 'default'
   3 () c_delta