hg prune: prevent empty call stable
authorPierre-Yves David <pierre-yves.david@logilab.fr>
Fri, 14 Sep 2012 15:36:29 +0200
branchstable
changeset 562 b1bdcb4506de
parent 561 897f6da2314e
child 563 61e883010b89
child 564 5559e5a4b656
hg prune: prevent empty call
hgext/evolve.py
--- a/hgext/evolve.py	Wed Sep 12 14:24:23 2012 +0200
+++ b/hgext/evolve.py	Fri Sep 14 15:36:29 2012 +0200
@@ -1722,6 +1722,8 @@
         try:
             new = set(noderange(repo, opts['new']))
             targetnodes = set(noderange(repo, revs))
+            if not targetnodes:
+                raise util.Abort('nothing to prune')
             if new:
                 sucs = tuple(repo[n] for n in new)
             else: