Mercurial > hg
comparison tests/test-mq-qrefresh.out @ 10397:8cb81d75730c
mq: add parent node IDs to MQ patches on qrefresh/qnew
The goal of this patch is to add the IDs of the parents of applied MQ patches
into the patch file headers whenever qnew or qrefresh are run.
This will serve as a reminder of when the patches last applied cleanly and
will let us do more intelligent things in the future, such as:
* Resolve conflicts found when qpushing to a new location by merging
instead of simply showing rejects.
* Display better diffs of versioned MQ patches because we can tell how the
patched files have changed in the meantime.
Here are the new rules this patch introduces. They are checked in this order:
* If a patch currently has old, plain-style patch headers ("From:" and
"Date:") do not change the style or add any new headers.
* If the 'mq.plain' configuration setting is true, only plain-style
headers will be used for all MQ patches.
* qnew will initialize new patches with HG-style headers and fill in the
"# Parent" header with the appropriate parent node.
* qrefresh will refresh the "# Parent" header with the current parent of
the current patch.
author | Steve Losh <steve@stevelosh.com> |
---|---|
date | Sun, 07 Feb 2010 10:47:54 -0500 |
parents | b8801b58bbd8 |
children | 4bb4895e1693 |
comparison
equal
deleted
inserted
replaced
10396:65a90c8e11ee | 10397:8cb81d75730c |
---|---|
29 +++ b/2/base | 29 +++ b/2/base |
30 @@ -1,1 +1,1 @@ | 30 @@ -1,1 +1,1 @@ |
31 -base | 31 -base |
32 +patched | 32 +patched |
33 % patch file contents | 33 % patch file contents |
34 # HG changeset patch | |
35 # Parent | |
34 mqbase | 36 mqbase |
35 | 37 |
36 diff -r b55ecdccb5cf 1/base | 38 diff -r b55ecdccb5cf 1/base |
37 --- a/1/base | 39 --- a/1/base |
38 +++ b/1/base | 40 +++ b/1/base |
71 +++ b/2/base | 73 +++ b/2/base |
72 @@ -1,1 +1,1 @@ | 74 @@ -1,1 +1,1 @@ |
73 -base | 75 -base |
74 +patched | 76 +patched |
75 % patch file contents | 77 % patch file contents |
78 # HG changeset patch | |
79 # Parent | |
76 mqbase | 80 mqbase |
77 | 81 |
78 diff -r b55ecdccb5cf 1/base | 82 diff -r b55ecdccb5cf 1/base |
79 --- a/1/base | 83 --- a/1/base |
80 +++ b/1/base | 84 +++ b/1/base |
107 +++ b/2/base | 111 +++ b/2/base |
108 @@ -1,1 +1,1 @@ | 112 @@ -1,1 +1,1 @@ |
109 -base | 113 -base |
110 +patched | 114 +patched |
111 % patch file contents | 115 % patch file contents |
116 # HG changeset patch | |
117 # Parent | |
112 mqbase | 118 mqbase |
113 | 119 |
114 diff -r b55ecdccb5cf 1/base | 120 diff -r b55ecdccb5cf 1/base |
115 --- a/1/base | 121 --- a/1/base |
116 +++ b/1/base | 122 +++ b/1/base |
143 +++ b/2/base | 149 +++ b/2/base |
144 @@ -1,1 +1,1 @@ | 150 @@ -1,1 +1,1 @@ |
145 -base | 151 -base |
146 +patched | 152 +patched |
147 % patch file contents | 153 % patch file contents |
154 # HG changeset patch | |
155 # Parent | |
148 mqbase | 156 mqbase |
149 | 157 |
150 diff -r b55ecdccb5cf 1/base | 158 diff -r b55ecdccb5cf 1/base |
151 --- a/1/base | 159 --- a/1/base |
152 +++ b/1/base | 160 +++ b/1/base |
179 --- /dev/null | 187 --- /dev/null |
180 +++ b/orphanchild | 188 +++ b/orphanchild |
181 @@ -0,0 +1,1 @@ | 189 @@ -0,0 +1,1 @@ |
182 +orphan | 190 +orphan |
183 % -- patch file content | 191 % -- patch file content |
192 # HG changeset patch | |
193 # Parent | |
184 mqbase | 194 mqbase |
185 | 195 |
186 diff -r b55ecdccb5cf 1/base | 196 diff -r b55ecdccb5cf 1/base |
187 --- a/1/base | 197 --- a/1/base |
188 +++ b/1/base | 198 +++ b/1/base |
271 M a | 281 M a |
272 % b after refresh | 282 % b after refresh |
273 b | 283 b |
274 b | 284 b |
275 % patch file after refresh | 285 % patch file after refresh |
286 # HG changeset patch | |
287 # Parent | |
288 | |
276 diff -r 1a60229be7ac b | 289 diff -r 1a60229be7ac b |
277 --- a/b | 290 --- a/b |
278 +++ b/b | 291 +++ b/b |
279 @@ -1,1 +1,2 @@ | 292 @@ -1,1 +1,2 @@ |
280 b | 293 b |