rebase: only advance phase on successful commit
authorMatt Mackall <mpm@selenic.com>
Wed, 18 Jan 2012 18:14:55 -0600
changeset 15923 4b088ae9d47a
parent 15922 23921c17299a
child 15924 3f132207e92f
rebase: only advance phase on successful commit
hgext/rebase.py
--- a/hgext/rebase.py	Wed Jan 18 17:23:54 2012 +0100
+++ b/hgext/rebase.py	Wed Jan 18 18:14:55 2012 -0600
@@ -375,7 +375,8 @@
         targetphase = max(ctx.phase(), phases.draft)
         # retractboundary doesn't overwrite upper phase inherited from parent
         newnode = repo[newrev].node()
-        phases.retractboundary(repo, targetphase, [newnode])
+        if newnode:
+            phases.retractboundary(repo, targetphase, [newnode])
         return newrev
     except util.Abort:
         # Invalidate the previous setparents