Mercurial > public > mercurial-scm > hg-stable
diff hgext/transplant.py @ 3758:889f7e74a0d9
transplant: log source node when recovering too.
author | Brendan Cully <brendan@kublai.com> |
---|---|
date | Fri, 01 Dec 2006 15:00:33 -0800 |
parents | faed44bab17b |
children | e96f97ca0358 |
line wrap: on
line diff
--- a/hgext/transplant.py Fri Dec 01 14:30:17 2006 -0800 +++ b/hgext/transplant.py Fri Dec 01 15:00:33 2006 -0800 @@ -238,6 +238,7 @@ revlog.short(n))) seriespath = os.path.join(self.path, 'series') if not os.path.exists(seriespath): + self.transplants.write() return nodes, merges = self.readseries() revmap = {} @@ -255,6 +256,7 @@ if not user or not date or not message or not parents[0]: raise util.Abort(_('transplant log file is corrupt')) + extra = {'transplant_source': node} wlock = repo.wlock() p1, p2 = repo.dirstate.parents() if p1 != parents[0]: @@ -262,7 +264,7 @@ revlog.hex(parents[0])) if merge: repo.dirstate.setparents(p1, parents[1]) - n = repo.commit(None, message, user, date, wlock=wlock) + n = repo.commit(None, message, user, date, wlock=wlock, extra=extra) if not n: raise util.Abort(_('commit failed')) if not merge: