Mercurial > public > mercurial-scm > hg-stable
diff mercurial/commands.py @ 27912:ae4e6b80f084 stable
backout: fix --no-commit option (issue5054)
author | Ruslan Sayfutdinov <sayfutdinov@fb.com> |
---|---|
date | Wed, 20 Jan 2016 08:16:58 -0800 |
parents | 645e78845383 |
children | f6d73c8756e2 |
line wrap: on
line diff
--- a/mercurial/commands.py Tue Jan 19 13:43:50 2016 -0800 +++ b/mercurial/commands.py Wed Jan 20 08:16:58 2016 -0800 @@ -653,11 +653,6 @@ repo.ui.status(_("use 'hg resolve' to retry unresolved " "file merges\n")) return 1 - elif opts.get('no_commit'): - msg = _("changeset %s backed out, " - "don't forget to commit.\n") - ui.status(msg % short(node)) - return 0 finally: ui.setconfig('ui', 'forcemerge', '', '') lockmod.release(dsguard) @@ -666,6 +661,11 @@ repo.dirstate.setbranch(branch) cmdutil.revert(ui, repo, rctx, repo.dirstate.parents()) + if opts.get('no_commit'): + msg = _("changeset %s backed out, " + "don't forget to commit.\n") + ui.status(msg % short(node)) + return 0 def commitfunc(ui, repo, message, match, opts): editform = 'backout'