Show More
@@ -861,13 +861,11 b' def _dobackout(ui, repo, node=None, rev=' | |||||
861 |
|
861 | |||
862 | ui.status( |
|
862 | ui.status( | |
863 | _(b'changeset %s backs out changeset %s\n') |
|
863 | _(b'changeset %s backs out changeset %s\n') | |
864 |
% (nice( |
|
864 | % (nice(newnode), nice(node)) | |
865 | ) |
|
865 | ) | |
866 | if opts.get(b'merge') and op1 != node: |
|
866 | if opts.get(b'merge') and op1 != node: | |
867 | hg.clean(repo, op1, show_stats=False) |
|
867 | hg.clean(repo, op1, show_stats=False) | |
868 | ui.status( |
|
868 | ui.status(_(b'merging with changeset %s\n') % nice(newnode)) | |
869 | _(b'merging with changeset %s\n') % nice(repo.changelog.tip()) |
|
|||
870 | ) |
|
|||
871 | overrides = {(b'ui', b'forcemerge'): opts.get(b'tool', b'')} |
|
869 | overrides = {(b'ui', b'forcemerge'): opts.get(b'tool', b'')} | |
872 | with ui.configoverride(overrides, b'backout'): |
|
870 | with ui.configoverride(overrides, b'backout'): | |
873 | return hg.merge(repo[b'tip']) |
|
871 | return hg.merge(repo[b'tip']) |
@@ -806,3 +806,18 b' Test usage of `hg resolve` in case of co' | |||||
806 | $ hg backout --merge --no-commit 2 |
|
806 | $ hg backout --merge --no-commit 2 | |
807 | abort: cannot specify both --no-commit and --merge |
|
807 | abort: cannot specify both --no-commit and --merge | |
808 | [255] |
|
808 | [255] | |
|
809 | ||||
|
810 | Ensure that backout out the same changeset twice performs correctly: | |||
|
811 | ||||
|
812 | $ hg backout 2 | |||
|
813 | removing 3 | |||
|
814 | changeset 3:8f188de730d9 backs out changeset 2:cccc23d9d68f | |||
|
815 | $ echo 4 > 4 | |||
|
816 | $ hg ci -A -m 4 | |||
|
817 | adding 4 | |||
|
818 | $ hg up 2 | |||
|
819 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |||
|
820 | $ hg backout 2 | |||
|
821 | removing 3 | |||
|
822 | created new head | |||
|
823 | changeset 3:8f188de730d9 backs out changeset 2:cccc23d9d68f |
General Comments 0
You need to be logged in to leave comments.
Login now