comparison hgext/rebase.py @ 27146:88fde8db5307

rebase: propagate extra dict from rebase source changeset This corrects extra propagation for the rebase command and the shelve command.
author Mike Edgar <adgar@google.com>
date Sat, 28 Nov 2015 04:11:14 -0500
parents 405320cd6198
children 3fe8cb40c9c5
comparison
equal deleted inserted replaced
27145:3a2fd83182fb 27146:88fde8db5307
613 repo.setparents(repo[p1].node(), repo[p2].node()) 613 repo.setparents(repo[p1].node(), repo[p2].node())
614 ctx = repo[rev] 614 ctx = repo[rev]
615 if commitmsg is None: 615 if commitmsg is None:
616 commitmsg = ctx.description() 616 commitmsg = ctx.description()
617 keepbranch = keepbranches and repo[p1].branch() != ctx.branch() 617 keepbranch = keepbranches and repo[p1].branch() != ctx.branch()
618 extra = {'rebase_source': ctx.hex()} 618 extra = ctx.extra().copy()
619 if not keepbranches:
620 del extra['branch']
621 extra['rebase_source'] = ctx.hex()
619 if extrafn: 622 if extrafn:
620 extrafn(ctx, extra) 623 extrafn(ctx, extra)
621 624
622 backup = repo.ui.backupconfig('phases', 'new-commit') 625 backup = repo.ui.backupconfig('phases', 'new-commit')
623 try: 626 try: