diff -r 4cf94aea9b1d -r d43d116a118c hgext/shelve.py --- a/hgext/shelve.py Wed Oct 01 14:59:33 2014 -0500 +++ b/hgext/shelve.py Wed Oct 08 07:47:11 2014 -0400 @@ -453,10 +453,12 @@ if not shelvectx in state.pendingctx.children(): # rebase was a no-op, so it produced no child commit shelvectx = state.pendingctx + else: + # only strip the shelvectx if the rebase produced it + state.stripnodes.append(shelvectx.node()) mergefiles(ui, repo, state.wctx, shelvectx) - state.stripnodes.append(shelvectx.node()) repair.strip(ui, repo, state.stripnodes, backup='none', topic='shelve') shelvedstate.clear(repo) unshelvecleanup(ui, repo, state.name, opts)