[PATCH 5 of 5] dispatch: exit with status 1 for an InterventionRequired exception (bc)
Augie Fackler
raf at durin42.com
Fri Feb 8 16:49:54 CST 2013
# HG changeset patch
# User Augie Fackler <raf at durin42.com>
# Date 1360361866 21600
# Node ID f7f9b0475f5b74df861bdef1684bef8c976e4196
# Parent c74fa66f8dd73ce2bb11b359cbfc71d570af7533
dispatch: exit with status 1 for an InterventionRequired exception (bc)
diff --git a/mercurial/dispatch.py b/mercurial/dispatch.py
--- a/mercurial/dispatch.py
+++ b/mercurial/dispatch.py
@@ -153,6 +153,7 @@
commands.help_(ui, 'shortlist')
except error.InterventionRequired, inst:
ui.warn("%s\n" % inst)
+ return 1
except util.Abort, inst:
ui.warn(_("abort: %s\n") % inst)
if inst.hint:
diff --git a/tests/test-histedit-fold.t b/tests/test-histedit-fold.t
--- a/tests/test-histedit-fold.t
+++ b/tests/test-histedit-fold.t
@@ -183,7 +183,7 @@
warning: conflicts during merge.
merging file incomplete! (edit conflicts, then use 'hg resolve --mark')
Fix up the change and run hg histedit --continue
- [255]
+ [1]
There were conflicts, we keep P1 content. This
should effectively drop the changes from +6.
$ hg status
@@ -248,7 +248,7 @@
warning: conflicts during merge.
merging file incomplete! (edit conflicts, then use 'hg resolve --mark')
Fix up the change and run hg histedit --continue
- [255]
+ [1]
$ cat > file << EOF
> 1
> 2
diff --git a/tests/test-histedit-obsolete.t b/tests/test-histedit-obsolete.t
--- a/tests/test-histedit-obsolete.t
+++ b/tests/test-histedit-obsolete.t
@@ -141,7 +141,7 @@
adding c
Make changes as needed, you may commit or record as needed now.
When you are finished, run hg histedit --continue to resume.
- [255]
+ [1]
$ echo c >> c
$ hg histedit --continue
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
@@ -280,7 +280,7 @@
adding f
Make changes as needed, you may commit or record as needed now.
When you are finished, run hg histedit --continue to resume.
- [255]
+ [1]
$ echo f >> f
$ hg histedit --continue
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
@@ -330,7 +330,7 @@
adding f
Make changes as needed, you may commit or record as needed now.
When you are finished, run hg histedit --continue to resume.
- [255]
+ [1]
$ echo f >> f
$ hg histedit --continue
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
diff --git a/tests/test-rebase-abort.t b/tests/test-rebase-abort.t
--- a/tests/test-rebase-abort.t
+++ b/tests/test-rebase-abort.t
@@ -56,7 +56,7 @@
warning: conflicts during merge.
merging common incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Abort:
@@ -127,7 +127,7 @@
warning: conflicts during merge.
merging c incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
$ hg tglog
@ 4:draft 'C1'
diff --git a/tests/test-rebase-bookmarks.t b/tests/test-rebase-bookmarks.t
--- a/tests/test-rebase-bookmarks.t
+++ b/tests/test-rebase-bookmarks.t
@@ -142,7 +142,7 @@
warning: conflicts during merge.
merging c incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
$ echo 'c' > c
$ hg resolve --mark c
$ hg rebase --continue
diff --git a/tests/test-rebase-check-restore.t b/tests/test-rebase-check-restore.t
--- a/tests/test-rebase-check-restore.t
+++ b/tests/test-rebase-check-restore.t
@@ -70,7 +70,7 @@
warning: conflicts during merge.
merging A incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Solve the conflict and go on:
@@ -123,7 +123,7 @@
warning: conflicts during merge.
merging A incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Solve the conflict and go on:
diff --git a/tests/test-rebase-conflicts.t b/tests/test-rebase-conflicts.t
--- a/tests/test-rebase-conflicts.t
+++ b/tests/test-rebase-conflicts.t
@@ -65,7 +65,7 @@
warning: conflicts during merge.
merging common incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Try to continue without solving the conflict:
diff --git a/tests/test-rebase-detach.t b/tests/test-rebase-detach.t
--- a/tests/test-rebase-detach.t
+++ b/tests/test-rebase-detach.t
@@ -375,7 +375,7 @@
warning: conflicts during merge.
merging H incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
$ hg resolve --all -t internal:local
$ hg rebase -c
saved backup bundle to $TESTTMP/a7/.hg/strip-backup/6215fafa5447-backup.hg (glob)
diff --git a/tests/test-rebase-interruptions.t b/tests/test-rebase-interruptions.t
--- a/tests/test-rebase-interruptions.t
+++ b/tests/test-rebase-interruptions.t
@@ -62,7 +62,7 @@
warning: conflicts during merge.
merging A incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Force a commit on C during the interruption:
@@ -98,7 +98,7 @@
warning: conflicts during merge.
merging A incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Solve the conflict and go on:
@@ -152,7 +152,7 @@
warning: conflicts during merge.
merging A incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Force a commit on B' during the interruption:
@@ -223,7 +223,7 @@
warning: conflicts during merge.
merging A incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Change phase on B and B'
diff --git a/tests/test-rebase-mq-skip.t b/tests/test-rebase-mq-skip.t
--- a/tests/test-rebase-mq-skip.t
+++ b/tests/test-rebase-mq-skip.t
@@ -109,7 +109,7 @@
$ HGMERGE=internal:fail hg rebase
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
$ HGMERGE=internal:local hg resolve --all
diff --git a/tests/test-rebase-mq.t b/tests/test-rebase-mq.t
--- a/tests/test-rebase-mq.t
+++ b/tests/test-rebase-mq.t
@@ -64,7 +64,7 @@
warning: conflicts during merge.
merging f incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Fix the 1st conflict:
@@ -75,7 +75,7 @@
warning: conflicts during merge.
merging f incomplete! (edit conflicts, then use 'hg resolve --mark')
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
Fix the 2nd conflict:
diff --git a/tests/test-rebase-parameters.t b/tests/test-rebase-parameters.t
--- a/tests/test-rebase-parameters.t
+++ b/tests/test-rebase-parameters.t
@@ -417,7 +417,7 @@
$ hg rebase -s 2 -d 1 --tool internal:fail
unresolved conflicts (see hg resolve, then hg rebase --continue)
- [255]
+ [1]
$ hg resolve -l
U c2
More information about the Mercurial-devel
mailing list