patchbomb: support --outgoing and revsets
authorPatrick Mezard <patrick@mezard.eu>
Sun, 24 Jun 2012 17:39:27 +0200
changeset 17177 ef507130fc92
parent 17176 2ab165cf3d8a
child 17178 8308f6284640
patchbomb: support --outgoing and revsets With --outgoing, input revisions were passed to getoutgoing() before being resolved.
hgext/patchbomb.py
tests/test-patchbomb.t
--- a/hgext/patchbomb.py	Sat Jul 14 19:21:31 2012 +0200
+++ b/hgext/patchbomb.py	Sun Jun 24 17:39:27 2012 +0200
@@ -277,7 +277,7 @@
         dest, branches = hg.parseurl(dest)
         revs, checkout = hg.addbranchrevs(repo, repo, branches, revs)
         if revs:
-            revs = [repo.lookup(rev) for rev in revs]
+            revs = [repo.lookup(r) for r in scmutil.revrange(repo, revs)]
         other = hg.peer(repo, opts, dest)
         ui.status(_('comparing with %s\n') % util.hidepassword(dest))
         repo.ui.pushbuffer()
--- a/tests/test-patchbomb.t	Sat Jul 14 19:21:31 2012 +0200
+++ b/tests/test-patchbomb.t	Sun Jun 24 17:39:27 2012 +0200
@@ -2103,7 +2103,7 @@
   o  0:8580ff50825a a
   
   $ hg phase --force --secret -r 10
-  $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t -r 6 -r 10
+  $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t -r 'rev(10) or rev(6)'
   comparing with ../t
   From [test]: test
   this patch series consists of 6 patches.