diff mercurial/commands.py @ 27147:804abe8999f3

graft: copy extra (except branch) when copying changesets
author Mike Edgar <adgar@google.com>
date Sat, 28 Nov 2015 04:11:38 -0500
parents 24440cc7b441
children 39163708825c
line wrap: on
line diff
--- a/mercurial/commands.py	Sat Nov 28 04:11:14 2015 -0500
+++ b/mercurial/commands.py	Sat Nov 28 04:11:38 2015 -0500
@@ -3831,10 +3831,10 @@
             if opts.get('dry_run'):
                 continue
 
-            source = ctx.extra().get('source')
-            extra = {}
+            extra = ctx.extra().copy()
+            del extra['branch']
+            source = extra.get('source')
             if source:
-                extra['source'] = source
                 extra['intermediate-source'] = ctx.hex()
             else:
                 extra['source'] = ctx.hex()