changeset 22042:8d99c107b041

shelve: use `targetphase` while unbundling This removes the last manual phase movement in shelve.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Tue, 05 Aug 2014 13:51:13 -0700
parents 97f86ce79abe
children 1274ff3f20a8
files hgext/shelve.py
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/shelve.py	Tue Aug 05 13:49:38 2014 -0700
+++ b/hgext/shelve.py	Tue Aug 05 13:51:13 2014 -0700
@@ -73,7 +73,8 @@
         try:
             gen = exchange.readbundle(self.repo.ui, fp, self.fname, self.vfs)
             changegroup.addchangegroup(self.repo, gen, 'unshelve',
-                                       'bundle:' + self.vfs.join(self.fname))
+                                       'bundle:' + self.vfs.join(self.fname),
+                                       targetphase=phases.secret)
         finally:
             fp.close()
 
@@ -579,8 +580,6 @@
 
         ui.quiet = True
         shelvedfile(repo, basename, 'hg').applybundle()
-        nodes = [ctx.node() for ctx in repo.set('%d:', oldtiprev)]
-        phases.retractboundary(repo, phases.secret, nodes)
 
         ui.quiet = oldquiet