[PATCH] merge: drop the quote around commit description
pierre-yves.david at ens-lyon.org
pierre-yves.david at ens-lyon.org
Thu May 29 19:30:39 UTC 2014
# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at fb.com>
# Date 1401129898 25200
# Mon May 26 11:44:58 2014 -0700
# Node ID 6a3a8f3e0aa9abae2de74ec98c41cd081c94a4c4
# Parent 0a8e7f81e8ae199d75241755534038f8201ae12c
merge: drop the quote around commit description.
We already have a ":" after the user name to denote the starts of the
description. The current usage of quote around the description is problematic as
the truncation to 80 chars is likely to drop the closing quote. This may
confuse syntax coloration in some editor.
diff --git a/mercurial/filemerge.py b/mercurial/filemerge.py
--- a/mercurial/filemerge.py
+++ b/mercurial/filemerge.py
@@ -296,11 +296,11 @@ def _formatconflictmarker(repo, ctx, tem
_defaultconflictmarker = ('{node|short} ' +
'{ifeq(tags, "tip", "", "{tags} ")}' +
'{if(bookmarks, "{bookmarks} ")}' +
'{ifeq(branch, "default", "", "{branch} ")}' +
- '- {author|user}: "{desc|firstline}"')
+ '- {author|user}: {desc|firstline}')
_defaultconflictlabels = ['local', 'other']
def _formatlabels(repo, fcd, fco, labels):
"""Formats the given labels using the conflict marker template.
diff --git a/tests/test-commit-amend.t b/tests/test-commit-amend.t
--- a/tests/test-commit-amend.t
+++ b/tests/test-commit-amend.t
@@ -587,11 +587,11 @@ Amend a merge changeset (with renames an
[1]
$ hg resolve -m cc
no more unresolved files
$ hg ci -m 'merge bar'
$ hg log --config diff.git=1 -pr .
- changeset: 23:29ee7aa200c8
+ changeset: 23:93cd4445f720
tag: tip
parent: 22:30d96aeaf27b
parent: 21:1aa437659d19
user: test
date: Thu Jan 01 00:00:00 1970 +0000
@@ -602,15 +602,15 @@ Amend a merge changeset (with renames an
copy to aa
diff --git a/cc b/cc
--- a/cc
+++ b/cc
@@ -1,1 +1,5 @@
- +<<<<<<< local: 30d96aeaf27b - test: "aa"
+ +<<<<<<< local: 30d96aeaf27b - test: aa
dd
+=======
+cc
- +>>>>>>> other: 1aa437659d19 bar - test: "aazzcc"
+ +>>>>>>> other: 1aa437659d19 bar - test: aazzcc
diff --git a/z b/zz
rename from z
rename to zz
$ hg debugrename aa
@@ -619,11 +619,11 @@ Amend a merge changeset (with renames an
zz renamed from z:69a1b67522704ec122181c0890bd16e9d3e7516a
$ hg debugrename cc
cc not renamed
$ hg ci --amend -m 'merge bar (amend message)'
$ hg log --config diff.git=1 -pr .
- changeset: 24:ba3eb3e8e8c2
+ changeset: 24:832b50f2c271
tag: tip
parent: 22:30d96aeaf27b
parent: 21:1aa437659d19
user: test
date: Thu Jan 01 00:00:00 1970 +0000
@@ -634,15 +634,15 @@ Amend a merge changeset (with renames an
copy to aa
diff --git a/cc b/cc
--- a/cc
+++ b/cc
@@ -1,1 +1,5 @@
- +<<<<<<< local: 30d96aeaf27b - test: "aa"
+ +<<<<<<< local: 30d96aeaf27b - test: aa
dd
+=======
+cc
- +>>>>>>> other: 1aa437659d19 bar - test: "aazzcc"
+ +>>>>>>> other: 1aa437659d19 bar - test: aazzcc
diff --git a/z b/zz
rename from z
rename to zz
$ hg debugrename aa
@@ -652,11 +652,11 @@ Amend a merge changeset (with renames an
$ hg debugrename cc
cc not renamed
$ hg mv zz z
$ hg ci --amend -m 'merge bar (undo rename)'
$ hg log --config diff.git=1 -pr .
- changeset: 26:0ce8747233f6
+ changeset: 26:bdafc5c72f74
tag: tip
parent: 22:30d96aeaf27b
parent: 21:1aa437659d19
user: test
date: Thu Jan 01 00:00:00 1970 +0000
@@ -667,15 +667,15 @@ Amend a merge changeset (with renames an
copy to aa
diff --git a/cc b/cc
--- a/cc
+++ b/cc
@@ -1,1 +1,5 @@
- +<<<<<<< local: 30d96aeaf27b - test: "aa"
+ +<<<<<<< local: 30d96aeaf27b - test: aa
dd
+=======
+cc
- +>>>>>>> other: 1aa437659d19 bar - test: "aazzcc"
+ +>>>>>>> other: 1aa437659d19 bar - test: aazzcc
$ hg debugrename z
z not renamed
Amend a merge changeset (with renames during the merge):
@@ -688,13 +688,13 @@ Amend a merge changeset (with renames du
$ hg merge -q bar
$ hg mv aa aaa
$ echo aa >> aaa
$ hg ci -m 'merge bar again'
$ hg log --config diff.git=1 -pr .
- changeset: 28:b8235574e741
+ changeset: 28:32f19415b634
tag: tip
- parent: 26:0ce8747233f6
+ parent: 26:bdafc5c72f74
parent: 27:4c94d5bc65f5
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: merge bar again
@@ -723,13 +723,13 @@ Amend a merge changeset (with renames du
$ hg debugrename aaa
aaa renamed from aa:37d9b5d994eab34eda9c16b195ace52c7b129980
$ hg mv aaa aa
$ hg ci --amend -m 'merge bar again (undo rename)'
$ hg log --config diff.git=1 -pr .
- changeset: 30:dbafc132c18a
+ changeset: 30:1e2a06b3d312
tag: tip
- parent: 26:0ce8747233f6
+ parent: 26:bdafc5c72f74
parent: 27:4c94d5bc65f5
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: merge bar again (undo rename)
@@ -763,25 +763,25 @@ Amend a merge changeset (with manifest-l
$ hg merge -q bar
local changed aa which remote deleted
use (c)hanged version or (d)elete? c
$ hg ci -m 'merge bar (with conflicts)'
$ hg log --config diff.git=1 -pr .
- changeset: 33:8b0c83445ff5
+ changeset: 33:97a298b0c59f
tag: tip
- parent: 32:f60ace0fe178
+ parent: 32:3d78ce4226b8
parent: 31:67db8847a540
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: merge bar (with conflicts)
$ hg rm aa
$ hg ci --amend -m 'merge bar (with conflicts, amended)'
$ hg log --config diff.git=1 -pr .
- changeset: 35:f9b6726d8bd2
+ changeset: 35:6de0c1bde1c8
tag: tip
- parent: 32:f60ace0fe178
+ parent: 32:3d78ce4226b8
parent: 31:67db8847a540
user: test
date: Thu Jan 01 00:00:00 1970 +0000
summary: merge bar (with conflicts, amended)
diff --git a/tests/test-conflict.t b/tests/test-conflict.t
--- a/tests/test-conflict.t
+++ b/tests/test-conflict.t
@@ -20,15 +20,15 @@
$ hg id
32e80765d7fe+75234512624c+ tip
$ cat a
- <<<<<<< local: 32e80765d7fe - test: "branch2"
+ <<<<<<< local: 32e80765d7fe - test: branch2
something else
=======
something
- >>>>>>> other: 75234512624c - test: "branch1"
+ >>>>>>> other: 75234512624c - test: branch1
$ hg status
M a
? a.orig
diff --git a/tests/test-keyword.t b/tests/test-keyword.t
--- a/tests/test-keyword.t
+++ b/tests/test-keyword.t
@@ -1047,15 +1047,15 @@ conflict: keyword should stay outside co
0 files updated, 0 files merged, 0 files removed, 1 files unresolved
use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
[1]
$ cat m
$Id$
- <<<<<<< local: 88a80c8d172e - test: "8bar"
+ <<<<<<< local: 88a80c8d172e - test: 8bar
bar
=======
foo
- >>>>>>> other: 85d2d2d732a5 - test: "simplemerge"
+ >>>>>>> other: 85d2d2d732a5 - test: simplemerge
resolve to local
$ HGMERGE=internal:local hg resolve -a
no more unresolved files
diff --git a/tests/test-merge-revert2.t b/tests/test-merge-revert2.t
--- a/tests/test-merge-revert2.t
+++ b/tests/test-merge-revert2.t
@@ -55,15 +55,15 @@
--- a/file1
+++ b/file1
@@ -1,3 +1,7 @@
added file1
another line of text
- +<<<<<<< working copy: c3fa057dd86f - test: "added file1 and file2"
+ +<<<<<<< working copy: c3fa057dd86f - test: added file1 and file2
+changed file1 different
+=======
changed file1
- +>>>>>>> destination: dfab7f3c2efb - test: "changed file1"
+ +>>>>>>> destination: dfab7f3c2efb - test: changed file1
$ hg status
M file1
? file1.orig
$ hg id
diff --git a/tests/test-merge-tools.t b/tests/test-merge-tools.t
--- a/tests/test-merge-tools.t
+++ b/tests/test-merge-tools.t
@@ -64,15 +64,15 @@ running from a devel copy, not a temp in
0 files updated, 0 files merged, 0 files removed, 1 files unresolved
use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
[1]
$ aftermerge
# cat f
- <<<<<<< local: ef83787e2614 - test: "revision 1"
+ <<<<<<< local: ef83787e2614 - test: revision 1
revision 1
=======
revision 2
- >>>>>>> other: 0185f4e0cf02 - test: "revision 2"
+ >>>>>>> other: 0185f4e0cf02 - test: revision 2
space
# hg stat
M f
? f.orig
diff --git a/tests/test-merge-types.t b/tests/test-merge-types.t
--- a/tests/test-merge-types.t
+++ b/tests/test-merge-types.t
@@ -288,22 +288,22 @@ h: l vs l, different
U d
U f
U h
$ tellmeabout a
a is a plain file with content:
- <<<<<<< local: 0139c5610547 - test: "2"
+ <<<<<<< local: 0139c5610547 - test: 2
2
=======
1
- >>>>>>> other: 97e29675e796 - test: "1"
+ >>>>>>> other: 97e29675e796 - test: 1
$ tellmeabout b
b is a plain file with content:
- <<<<<<< local: 0139c5610547 - test: "2"
+ <<<<<<< local: 0139c5610547 - test: 2
2
=======
1
- >>>>>>> other: 97e29675e796 - test: "1"
+ >>>>>>> other: 97e29675e796 - test: 1
$ tellmeabout c
c is a plain file with content:
x
$ tellmeabout d
d is a symlink:
@@ -343,22 +343,22 @@ h: l vs l, different
3 files updated, 0 files merged, 0 files removed, 5 files unresolved
use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
[1]
$ tellmeabout a
a is a plain file with content:
- <<<<<<< local: 97e29675e796 - test: "1"
+ <<<<<<< local: 97e29675e796 - test: 1
1
=======
2
- >>>>>>> other: 0139c5610547 - test: "2"
+ >>>>>>> other: 0139c5610547 - test: 2
$ tellmeabout b
b is an executable file with content:
- <<<<<<< local: 97e29675e796 - test: "1"
+ <<<<<<< local: 97e29675e796 - test: 1
1
=======
2
- >>>>>>> other: 0139c5610547 - test: "2"
+ >>>>>>> other: 0139c5610547 - test: 2
$ tellmeabout c
c is an executable file with content:
x
$ tellmeabout d
d is an executable file with content:
diff --git a/tests/test-merge7.t b/tests/test-merge7.t
--- a/tests/test-merge7.t
+++ b/tests/test-merge7.t
@@ -96,15 +96,15 @@ pull and merge from test-a again
use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
[1]
$ cat test.txt
one
- <<<<<<< local: 50c3a7e29886 - test: "Merge 1"
+ <<<<<<< local: 50c3a7e29886 - test: Merge 1
two-point-five
=======
two-point-one
- >>>>>>> other: 40d11a4173a8 - test: "two -> two-point-one"
+ >>>>>>> other: 40d11a4173a8 - test: two -> two-point-one
three
$ hg debugindex test.txt
rev offset length ..... linkrev nodeid p1 p2 (re)
0 0 7 ..... 0 01365c4cca56 000000000000 000000000000 (re)
diff --git a/tests/test-shelve.t b/tests/test-shelve.t
--- a/tests/test-shelve.t
+++ b/tests/test-shelve.t
@@ -208,15 +208,15 @@ ensure that we have a merge with unresol
diff --git a/a/a b/a/a
--- a/a/a
+++ b/a/a
@@ -1,2 +1,6 @@
a
- +<<<<<<< dest: * - shelve: "pending changes temporary commit" (glob)
+ +<<<<<<< dest: * - shelve: pending changes temporary commit (glob)
c
+=======
+a
- +>>>>>>> source: * - shelve: "changes to '[mq]: second.patch'" (glob)
+ +>>>>>>> source: 4702e8911fe0 - shelve: changes to '[mq]: second.patch'
diff --git a/b.rename/b b/b.rename/b
new file mode 100644
--- /dev/null
+++ b/b.rename/b
@@ -0,0 +1,1 @@
@@ -600,15 +600,15 @@ unshelve and conflicts with tracked and
$ hg st
M f
? f.orig
$ cat f
- <<<<<<< dest: 5f6b880e719b - shelve: "pending changes temporary commit"
+ <<<<<<< dest: 5f6b880e719b - shelve: pending changes temporary commit
g
=======
f
- >>>>>>> source: 23b29cada8ba - shelve: "changes to 'commit stuff'"
+ >>>>>>> source: 23b29cada8ba - shelve: changes to 'commit stuff'
$ cat f.orig
g
$ hg unshelve --abort
rebase aborted
unshelve of 'default' aborted
@@ -643,15 +643,15 @@ unshelve and conflicts with tracked and
[1]
$ hg st
M f
? f.orig
$ cat f
- <<<<<<< dest: 6b563750f973 - test: "intermediate other change"
+ <<<<<<< dest: * - test: intermediate other change (glob)
g
=======
f
- >>>>>>> source: 23b29cada8ba - shelve: "changes to 'commit stuff'"
+ >>>>>>> source: 23b29cada8ba - shelve: changes to 'commit stuff'
$ cat f.orig
g
$ hg unshelve --abort
rebase aborted
no changes needed to a
diff --git a/tests/test-subrepo.t b/tests/test-subrepo.t
--- a/tests/test-subrepo.t
+++ b/tests/test-subrepo.t
@@ -296,15 +296,15 @@ merge tests
(branch merge, don't forget to commit)
should conflict
$ cat t/t
- <<<<<<< local: 20a0db6fbf6c - test: "10"
+ <<<<<<< local: 20a0db6fbf6c - test: 10
conflict
=======
t3
- >>>>>>> other: 7af322bc1198 - test: "7"
+ >>>>>>> other: 7af322bc1198 - test: 7
clone
$ cd ..
$ hg clone t tc
More information about the Mercurial-devel
mailing list