Mercurial > evolve
changeset 1056:edfb9a0ad085
merge with stable
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Thu, 14 Aug 2014 15:26:55 -0700 |
parents | d2fe19c818ea (current diff) cfe1b9d3e5d9 (diff) |
children | 00bc31523074 |
files | |
diffstat | 2 files changed, 7 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/README Fri Aug 08 23:16:24 2014 -0700 +++ b/README Thu Aug 14 15:26:55 2014 -0700 @@ -57,7 +57,7 @@ Changelog ========= -4.0.1 -- 2014-08-08 +4.1.0 -- 2014-08-08 - amend: add -D/--current-date option - amend: add -U/--current-user option
--- a/hgext/evolve.py Fri Aug 08 23:16:24 2014 -0700 +++ b/hgext/evolve.py Thu Aug 14 15:26:55 2014 -0700 @@ -852,7 +852,7 @@ if not orig.p2().rev() == node.nullrev: raise util.Abort( 'no support for evolving merge changesets yet', - hint="Redo the merge a use `hg prune` to obsolete the old one") + hint="Redo the merge and use `hg prune` to obsolete the old one") destbookmarks = repo.nodebookmarks(dest.node()) nodesrc = orig.node() destphase = repo[nodesrc].phase() @@ -933,6 +933,8 @@ def tryimportone(orig, ui, repo, hunk, parents, opts, *args, **kwargs): extracted = patch.extract(ui, hunk) expected = extracted[5] + if extracted is not None: + expected = node.bin(expected) oldextract = patch.extract try: patch.extract = lambda ui, hunk: extracted @@ -940,11 +942,12 @@ finally: patch.extract = oldextract created = ret[1] - if opts['obsolete'] and created is not None and created != expected: + if (opts['obsolete'] and None not in (created, expected) + and created != expected): tr = repo.transaction('import-obs') try: metadata = {'user': ui.username()} - repo.obsstore.create(tr, node.bin(expected), (created,), + repo.obsstore.create(tr, expected, (created,), metadata=metadata) tr.close() finally: