changeset 2664:9b8df8dceeed

Add qtip and qbase to mq qlookup.
author Brendan Cully <brendan@kublai.com>
date Thu, 20 Jul 2006 11:52:28 -0700
parents 96950d39171d
children 2efcd2b4c9fe 133811a7688b
files hgext/mq.py
diffstat 1 files changed, 9 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/mq.py	Thu Jul 20 11:52:28 2006 -0700
+++ b/hgext/mq.py	Thu Jul 20 11:52:28 2006 -0700
@@ -1279,6 +1279,15 @@
             return oldlookup(key)
         except hg.RepoError:
             q = repomap[repo]
+
+            qpatchnames = { 'qtip': -1, 'qbase': 0 }
+            if key in qpatchnames:
+                if len(q.applied) == 0:
+                    self.ui.warn('No patches applied\n')
+                    raise
+                patch = q.applied[qpatchnames[key]].split(':')[0]
+                return revlog.bin(patch)
+
             patch = q.isapplied(key)
             if not patch:
                 raise