hgext/rebase.py
changeset 8706 25e9c71b89de
parent 8702 3d44f1a68353
child 8934 9dda4c73fc3b
equal deleted inserted replaced
8705:509083f54e52 8706:25e9c71b89de
   172             commitmsg = repo[rev].description()
   172             commitmsg = repo[rev].description()
   173         # Commit might fail if unresolved files exist
   173         # Commit might fail if unresolved files exist
   174         extra = {'rebase_source': repo[rev].hex()}
   174         extra = {'rebase_source': repo[rev].hex()}
   175         if extrafn:
   175         if extrafn:
   176             extrafn(repo[rev], extra)
   176             extrafn(repo[rev], extra)
   177         newrev = repo.commit(None,
   177         newrev = repo.commit(text=commitmsg, user=repo[rev].user(),
   178                             text=commitmsg,
   178                              date=repo[rev].date(), extra=extra)
   179                             user=repo[rev].user(),
       
   180                             date=repo[rev].date(),
       
   181                             extra=extra)
       
   182         repo.dirstate.setbranch(repo[newrev].branch())
   179         repo.dirstate.setbranch(repo[newrev].branch())
   183         return newrev
   180         return newrev
   184     except util.Abort:
   181     except util.Abort:
   185         # Invalidate the previous setparents
   182         # Invalidate the previous setparents
   186         repo.dirstate.invalidate()
   183         repo.dirstate.invalidate()