Show More
@@ -1,1030 +1,1030 b'' | |||||
1 | test merge-tools configuration - mostly exercising filemerge.py |
|
1 | test merge-tools configuration - mostly exercising filemerge.py | |
2 |
|
2 | |||
3 | $ unset HGMERGE # make sure HGMERGE doesn't interfere with the test |
|
3 | $ unset HGMERGE # make sure HGMERGE doesn't interfere with the test | |
4 | $ hg init |
|
4 | $ hg init | |
5 |
|
5 | |||
6 | revision 0 |
|
6 | revision 0 | |
7 |
|
7 | |||
8 | $ echo "revision 0" > f |
|
8 | $ echo "revision 0" > f | |
9 | $ echo "space" >> f |
|
9 | $ echo "space" >> f | |
10 | $ hg commit -Am "revision 0" |
|
10 | $ hg commit -Am "revision 0" | |
11 | adding f |
|
11 | adding f | |
12 |
|
12 | |||
13 | revision 1 |
|
13 | revision 1 | |
14 |
|
14 | |||
15 | $ echo "revision 1" > f |
|
15 | $ echo "revision 1" > f | |
16 | $ echo "space" >> f |
|
16 | $ echo "space" >> f | |
17 | $ hg commit -Am "revision 1" |
|
17 | $ hg commit -Am "revision 1" | |
18 | $ hg update 0 > /dev/null |
|
18 | $ hg update 0 > /dev/null | |
19 |
|
19 | |||
20 | revision 2 |
|
20 | revision 2 | |
21 |
|
21 | |||
22 | $ echo "revision 2" > f |
|
22 | $ echo "revision 2" > f | |
23 | $ echo "space" >> f |
|
23 | $ echo "space" >> f | |
24 | $ hg commit -Am "revision 2" |
|
24 | $ hg commit -Am "revision 2" | |
25 | created new head |
|
25 | created new head | |
26 | $ hg update 0 > /dev/null |
|
26 | $ hg update 0 > /dev/null | |
27 |
|
27 | |||
28 | revision 3 - simple to merge |
|
28 | revision 3 - simple to merge | |
29 |
|
29 | |||
30 | $ echo "revision 3" >> f |
|
30 | $ echo "revision 3" >> f | |
31 | $ hg commit -Am "revision 3" |
|
31 | $ hg commit -Am "revision 3" | |
32 | created new head |
|
32 | created new head | |
33 |
|
33 | |||
34 | revision 4 - hard to merge |
|
34 | revision 4 - hard to merge | |
35 |
|
35 | |||
36 | $ hg update 0 > /dev/null |
|
36 | $ hg update 0 > /dev/null | |
37 | $ echo "revision 4" > f |
|
37 | $ echo "revision 4" > f | |
38 | $ hg commit -Am "revision 4" |
|
38 | $ hg commit -Am "revision 4" | |
39 | created new head |
|
39 | created new head | |
40 |
|
40 | |||
41 | $ echo "[merge-tools]" > .hg/hgrc |
|
41 | $ echo "[merge-tools]" > .hg/hgrc | |
42 |
|
42 | |||
43 | $ beforemerge() { |
|
43 | $ beforemerge() { | |
44 | > cat .hg/hgrc |
|
44 | > cat .hg/hgrc | |
45 | > echo "# hg update -C 1" |
|
45 | > echo "# hg update -C 1" | |
46 | > hg update -C 1 > /dev/null |
|
46 | > hg update -C 1 > /dev/null | |
47 | > } |
|
47 | > } | |
48 | $ aftermerge() { |
|
48 | $ aftermerge() { | |
49 | > echo "# cat f" |
|
49 | > echo "# cat f" | |
50 | > cat f |
|
50 | > cat f | |
51 | > echo "# hg stat" |
|
51 | > echo "# hg stat" | |
52 | > hg stat |
|
52 | > hg stat | |
53 | > rm -f f.orig |
|
53 | > rm -f f.orig | |
54 | > } |
|
54 | > } | |
55 |
|
55 | |||
56 | Tool selection |
|
56 | Tool selection | |
57 |
|
57 | |||
58 | default is internal merge: |
|
58 | default is internal merge: | |
59 |
|
59 | |||
60 | $ beforemerge |
|
60 | $ beforemerge | |
61 | [merge-tools] |
|
61 | [merge-tools] | |
62 | # hg update -C 1 |
|
62 | # hg update -C 1 | |
63 |
|
63 | |||
64 | hg merge -r 2 |
|
64 | hg merge -r 2 | |
65 | override $PATH to ensure hgmerge not visible; use $PYTHON in case we're |
|
65 | override $PATH to ensure hgmerge not visible; use $PYTHON in case we're | |
66 | running from a devel copy, not a temp installation |
|
66 | running from a devel copy, not a temp installation | |
67 |
|
67 | |||
68 | $ PATH="$BINDIR" $PYTHON "$BINDIR"/hg merge -r 2 |
|
68 | $ PATH="$BINDIR:/usr/sbin" $PYTHON "$BINDIR"/hg merge -r 2 | |
69 | merging f |
|
69 | merging f | |
70 | warning: conflicts during merge. |
|
70 | warning: conflicts during merge. | |
71 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') |
|
71 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') | |
72 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
72 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
73 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
73 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
74 | [1] |
|
74 | [1] | |
75 | $ aftermerge |
|
75 | $ aftermerge | |
76 | # cat f |
|
76 | # cat f | |
77 | <<<<<<< local: ef83787e2614 - test: revision 1 |
|
77 | <<<<<<< local: ef83787e2614 - test: revision 1 | |
78 | revision 1 |
|
78 | revision 1 | |
79 | ======= |
|
79 | ======= | |
80 | revision 2 |
|
80 | revision 2 | |
81 | >>>>>>> other: 0185f4e0cf02 - test: revision 2 |
|
81 | >>>>>>> other: 0185f4e0cf02 - test: revision 2 | |
82 | space |
|
82 | space | |
83 | # hg stat |
|
83 | # hg stat | |
84 | M f |
|
84 | M f | |
85 | ? f.orig |
|
85 | ? f.orig | |
86 |
|
86 | |||
87 | simplest hgrc using false for merge: |
|
87 | simplest hgrc using false for merge: | |
88 |
|
88 | |||
89 | $ echo "false.whatever=" >> .hg/hgrc |
|
89 | $ echo "false.whatever=" >> .hg/hgrc | |
90 | $ beforemerge |
|
90 | $ beforemerge | |
91 | [merge-tools] |
|
91 | [merge-tools] | |
92 | false.whatever= |
|
92 | false.whatever= | |
93 | # hg update -C 1 |
|
93 | # hg update -C 1 | |
94 | $ hg merge -r 2 |
|
94 | $ hg merge -r 2 | |
95 | merging f |
|
95 | merging f | |
96 | merging f failed! |
|
96 | merging f failed! | |
97 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
97 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
98 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
98 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
99 | [1] |
|
99 | [1] | |
100 | $ aftermerge |
|
100 | $ aftermerge | |
101 | # cat f |
|
101 | # cat f | |
102 | revision 1 |
|
102 | revision 1 | |
103 | space |
|
103 | space | |
104 | # hg stat |
|
104 | # hg stat | |
105 | M f |
|
105 | M f | |
106 | ? f.orig |
|
106 | ? f.orig | |
107 |
|
107 | |||
108 | #if unix-permissions |
|
108 | #if unix-permissions | |
109 |
|
109 | |||
110 | unexecutable file in $PATH shouldn't be found: |
|
110 | unexecutable file in $PATH shouldn't be found: | |
111 |
|
111 | |||
112 | $ echo "echo fail" > false |
|
112 | $ echo "echo fail" > false | |
113 | $ hg up -qC 1 |
|
113 | $ hg up -qC 1 | |
114 | $ PATH="`pwd`:$BINDIR" $PYTHON "$BINDIR"/hg merge -r 2 |
|
114 | $ PATH="`pwd`:$BINDIR:/usr/sbin" $PYTHON "$BINDIR"/hg merge -r 2 | |
115 | merging f |
|
115 | merging f | |
116 | warning: conflicts during merge. |
|
116 | warning: conflicts during merge. | |
117 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') |
|
117 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') | |
118 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
118 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
119 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
119 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
120 | [1] |
|
120 | [1] | |
121 | $ rm false |
|
121 | $ rm false | |
122 |
|
122 | |||
123 | #endif |
|
123 | #endif | |
124 |
|
124 | |||
125 | executable directory in $PATH shouldn't be found: |
|
125 | executable directory in $PATH shouldn't be found: | |
126 |
|
126 | |||
127 | $ mkdir false |
|
127 | $ mkdir false | |
128 | $ hg up -qC 1 |
|
128 | $ hg up -qC 1 | |
129 | $ PATH="`pwd`:$BINDIR" $PYTHON "$BINDIR"/hg merge -r 2 |
|
129 | $ PATH="`pwd`:$BINDIR:/usr/sbin" $PYTHON "$BINDIR"/hg merge -r 2 | |
130 | merging f |
|
130 | merging f | |
131 | warning: conflicts during merge. |
|
131 | warning: conflicts during merge. | |
132 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') |
|
132 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') | |
133 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
133 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
134 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
134 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
135 | [1] |
|
135 | [1] | |
136 | $ rmdir false |
|
136 | $ rmdir false | |
137 |
|
137 | |||
138 | true with higher .priority gets precedence: |
|
138 | true with higher .priority gets precedence: | |
139 |
|
139 | |||
140 | $ echo "true.priority=1" >> .hg/hgrc |
|
140 | $ echo "true.priority=1" >> .hg/hgrc | |
141 | $ beforemerge |
|
141 | $ beforemerge | |
142 | [merge-tools] |
|
142 | [merge-tools] | |
143 | false.whatever= |
|
143 | false.whatever= | |
144 | true.priority=1 |
|
144 | true.priority=1 | |
145 | # hg update -C 1 |
|
145 | # hg update -C 1 | |
146 | $ hg merge -r 2 |
|
146 | $ hg merge -r 2 | |
147 | merging f |
|
147 | merging f | |
148 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
148 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
149 | (branch merge, don't forget to commit) |
|
149 | (branch merge, don't forget to commit) | |
150 | $ aftermerge |
|
150 | $ aftermerge | |
151 | # cat f |
|
151 | # cat f | |
152 | revision 1 |
|
152 | revision 1 | |
153 | space |
|
153 | space | |
154 | # hg stat |
|
154 | # hg stat | |
155 | M f |
|
155 | M f | |
156 |
|
156 | |||
157 | unless lowered on command line: |
|
157 | unless lowered on command line: | |
158 |
|
158 | |||
159 | $ beforemerge |
|
159 | $ beforemerge | |
160 | [merge-tools] |
|
160 | [merge-tools] | |
161 | false.whatever= |
|
161 | false.whatever= | |
162 | true.priority=1 |
|
162 | true.priority=1 | |
163 | # hg update -C 1 |
|
163 | # hg update -C 1 | |
164 | $ hg merge -r 2 --config merge-tools.true.priority=-7 |
|
164 | $ hg merge -r 2 --config merge-tools.true.priority=-7 | |
165 | merging f |
|
165 | merging f | |
166 | merging f failed! |
|
166 | merging f failed! | |
167 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
167 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
168 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
168 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
169 | [1] |
|
169 | [1] | |
170 | $ aftermerge |
|
170 | $ aftermerge | |
171 | # cat f |
|
171 | # cat f | |
172 | revision 1 |
|
172 | revision 1 | |
173 | space |
|
173 | space | |
174 | # hg stat |
|
174 | # hg stat | |
175 | M f |
|
175 | M f | |
176 | ? f.orig |
|
176 | ? f.orig | |
177 |
|
177 | |||
178 | or false set higher on command line: |
|
178 | or false set higher on command line: | |
179 |
|
179 | |||
180 | $ beforemerge |
|
180 | $ beforemerge | |
181 | [merge-tools] |
|
181 | [merge-tools] | |
182 | false.whatever= |
|
182 | false.whatever= | |
183 | true.priority=1 |
|
183 | true.priority=1 | |
184 | # hg update -C 1 |
|
184 | # hg update -C 1 | |
185 | $ hg merge -r 2 --config merge-tools.false.priority=117 |
|
185 | $ hg merge -r 2 --config merge-tools.false.priority=117 | |
186 | merging f |
|
186 | merging f | |
187 | merging f failed! |
|
187 | merging f failed! | |
188 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
188 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
189 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
189 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
190 | [1] |
|
190 | [1] | |
191 | $ aftermerge |
|
191 | $ aftermerge | |
192 | # cat f |
|
192 | # cat f | |
193 | revision 1 |
|
193 | revision 1 | |
194 | space |
|
194 | space | |
195 | # hg stat |
|
195 | # hg stat | |
196 | M f |
|
196 | M f | |
197 | ? f.orig |
|
197 | ? f.orig | |
198 |
|
198 | |||
199 | or true.executable not found in PATH: |
|
199 | or true.executable not found in PATH: | |
200 |
|
200 | |||
201 | $ beforemerge |
|
201 | $ beforemerge | |
202 | [merge-tools] |
|
202 | [merge-tools] | |
203 | false.whatever= |
|
203 | false.whatever= | |
204 | true.priority=1 |
|
204 | true.priority=1 | |
205 | # hg update -C 1 |
|
205 | # hg update -C 1 | |
206 | $ hg merge -r 2 --config merge-tools.true.executable=nonexistentmergetool |
|
206 | $ hg merge -r 2 --config merge-tools.true.executable=nonexistentmergetool | |
207 | merging f |
|
207 | merging f | |
208 | merging f failed! |
|
208 | merging f failed! | |
209 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
209 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
210 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
210 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
211 | [1] |
|
211 | [1] | |
212 | $ aftermerge |
|
212 | $ aftermerge | |
213 | # cat f |
|
213 | # cat f | |
214 | revision 1 |
|
214 | revision 1 | |
215 | space |
|
215 | space | |
216 | # hg stat |
|
216 | # hg stat | |
217 | M f |
|
217 | M f | |
218 | ? f.orig |
|
218 | ? f.orig | |
219 |
|
219 | |||
220 | or true.executable with bogus path: |
|
220 | or true.executable with bogus path: | |
221 |
|
221 | |||
222 | $ beforemerge |
|
222 | $ beforemerge | |
223 | [merge-tools] |
|
223 | [merge-tools] | |
224 | false.whatever= |
|
224 | false.whatever= | |
225 | true.priority=1 |
|
225 | true.priority=1 | |
226 | # hg update -C 1 |
|
226 | # hg update -C 1 | |
227 | $ hg merge -r 2 --config merge-tools.true.executable=/nonexistent/mergetool |
|
227 | $ hg merge -r 2 --config merge-tools.true.executable=/nonexistent/mergetool | |
228 | merging f |
|
228 | merging f | |
229 | merging f failed! |
|
229 | merging f failed! | |
230 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
230 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
231 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
231 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
232 | [1] |
|
232 | [1] | |
233 | $ aftermerge |
|
233 | $ aftermerge | |
234 | # cat f |
|
234 | # cat f | |
235 | revision 1 |
|
235 | revision 1 | |
236 | space |
|
236 | space | |
237 | # hg stat |
|
237 | # hg stat | |
238 | M f |
|
238 | M f | |
239 | ? f.orig |
|
239 | ? f.orig | |
240 |
|
240 | |||
241 | but true.executable set to cat found in PATH works: |
|
241 | but true.executable set to cat found in PATH works: | |
242 |
|
242 | |||
243 | $ echo "true.executable=cat" >> .hg/hgrc |
|
243 | $ echo "true.executable=cat" >> .hg/hgrc | |
244 | $ beforemerge |
|
244 | $ beforemerge | |
245 | [merge-tools] |
|
245 | [merge-tools] | |
246 | false.whatever= |
|
246 | false.whatever= | |
247 | true.priority=1 |
|
247 | true.priority=1 | |
248 | true.executable=cat |
|
248 | true.executable=cat | |
249 | # hg update -C 1 |
|
249 | # hg update -C 1 | |
250 | $ hg merge -r 2 |
|
250 | $ hg merge -r 2 | |
251 | merging f |
|
251 | merging f | |
252 | revision 1 |
|
252 | revision 1 | |
253 | space |
|
253 | space | |
254 | revision 0 |
|
254 | revision 0 | |
255 | space |
|
255 | space | |
256 | revision 2 |
|
256 | revision 2 | |
257 | space |
|
257 | space | |
258 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
258 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
259 | (branch merge, don't forget to commit) |
|
259 | (branch merge, don't forget to commit) | |
260 | $ aftermerge |
|
260 | $ aftermerge | |
261 | # cat f |
|
261 | # cat f | |
262 | revision 1 |
|
262 | revision 1 | |
263 | space |
|
263 | space | |
264 | # hg stat |
|
264 | # hg stat | |
265 | M f |
|
265 | M f | |
266 |
|
266 | |||
267 | and true.executable set to cat with path works: |
|
267 | and true.executable set to cat with path works: | |
268 |
|
268 | |||
269 | $ beforemerge |
|
269 | $ beforemerge | |
270 | [merge-tools] |
|
270 | [merge-tools] | |
271 | false.whatever= |
|
271 | false.whatever= | |
272 | true.priority=1 |
|
272 | true.priority=1 | |
273 | true.executable=cat |
|
273 | true.executable=cat | |
274 | # hg update -C 1 |
|
274 | # hg update -C 1 | |
275 | $ hg merge -r 2 --config merge-tools.true.executable=cat |
|
275 | $ hg merge -r 2 --config merge-tools.true.executable=cat | |
276 | merging f |
|
276 | merging f | |
277 | revision 1 |
|
277 | revision 1 | |
278 | space |
|
278 | space | |
279 | revision 0 |
|
279 | revision 0 | |
280 | space |
|
280 | space | |
281 | revision 2 |
|
281 | revision 2 | |
282 | space |
|
282 | space | |
283 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
283 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
284 | (branch merge, don't forget to commit) |
|
284 | (branch merge, don't forget to commit) | |
285 | $ aftermerge |
|
285 | $ aftermerge | |
286 | # cat f |
|
286 | # cat f | |
287 | revision 1 |
|
287 | revision 1 | |
288 | space |
|
288 | space | |
289 | # hg stat |
|
289 | # hg stat | |
290 | M f |
|
290 | M f | |
291 |
|
291 | |||
292 | #if unix-permissions |
|
292 | #if unix-permissions | |
293 |
|
293 | |||
294 | environment variables in true.executable are handled: |
|
294 | environment variables in true.executable are handled: | |
295 |
|
295 | |||
296 | $ echo 'echo "custom merge tool"' > .hg/merge.sh |
|
296 | $ echo 'echo "custom merge tool"' > .hg/merge.sh | |
297 | $ beforemerge |
|
297 | $ beforemerge | |
298 | [merge-tools] |
|
298 | [merge-tools] | |
299 | false.whatever= |
|
299 | false.whatever= | |
300 | true.priority=1 |
|
300 | true.priority=1 | |
301 | true.executable=cat |
|
301 | true.executable=cat | |
302 | # hg update -C 1 |
|
302 | # hg update -C 1 | |
303 | $ hg --config merge-tools.true.executable='sh' \ |
|
303 | $ hg --config merge-tools.true.executable='sh' \ | |
304 | > --config merge-tools.true.args=.hg/merge.sh \ |
|
304 | > --config merge-tools.true.args=.hg/merge.sh \ | |
305 | > merge -r 2 |
|
305 | > merge -r 2 | |
306 | merging f |
|
306 | merging f | |
307 | custom merge tool |
|
307 | custom merge tool | |
308 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
308 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
309 | (branch merge, don't forget to commit) |
|
309 | (branch merge, don't forget to commit) | |
310 | $ aftermerge |
|
310 | $ aftermerge | |
311 | # cat f |
|
311 | # cat f | |
312 | revision 1 |
|
312 | revision 1 | |
313 | space |
|
313 | space | |
314 | # hg stat |
|
314 | # hg stat | |
315 | M f |
|
315 | M f | |
316 |
|
316 | |||
317 | #endif |
|
317 | #endif | |
318 |
|
318 | |||
319 | Tool selection and merge-patterns |
|
319 | Tool selection and merge-patterns | |
320 |
|
320 | |||
321 | merge-patterns specifies new tool false: |
|
321 | merge-patterns specifies new tool false: | |
322 |
|
322 | |||
323 | $ beforemerge |
|
323 | $ beforemerge | |
324 | [merge-tools] |
|
324 | [merge-tools] | |
325 | false.whatever= |
|
325 | false.whatever= | |
326 | true.priority=1 |
|
326 | true.priority=1 | |
327 | true.executable=cat |
|
327 | true.executable=cat | |
328 | # hg update -C 1 |
|
328 | # hg update -C 1 | |
329 | $ hg merge -r 2 --config merge-patterns.f=false |
|
329 | $ hg merge -r 2 --config merge-patterns.f=false | |
330 | merging f |
|
330 | merging f | |
331 | merging f failed! |
|
331 | merging f failed! | |
332 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
332 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
333 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
333 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
334 | [1] |
|
334 | [1] | |
335 | $ aftermerge |
|
335 | $ aftermerge | |
336 | # cat f |
|
336 | # cat f | |
337 | revision 1 |
|
337 | revision 1 | |
338 | space |
|
338 | space | |
339 | # hg stat |
|
339 | # hg stat | |
340 | M f |
|
340 | M f | |
341 | ? f.orig |
|
341 | ? f.orig | |
342 |
|
342 | |||
343 | merge-patterns specifies executable not found in PATH and gets warning: |
|
343 | merge-patterns specifies executable not found in PATH and gets warning: | |
344 |
|
344 | |||
345 | $ beforemerge |
|
345 | $ beforemerge | |
346 | [merge-tools] |
|
346 | [merge-tools] | |
347 | false.whatever= |
|
347 | false.whatever= | |
348 | true.priority=1 |
|
348 | true.priority=1 | |
349 | true.executable=cat |
|
349 | true.executable=cat | |
350 | # hg update -C 1 |
|
350 | # hg update -C 1 | |
351 | $ hg merge -r 2 --config merge-patterns.f=true --config merge-tools.true.executable=nonexistentmergetool |
|
351 | $ hg merge -r 2 --config merge-patterns.f=true --config merge-tools.true.executable=nonexistentmergetool | |
352 | couldn't find merge tool true specified for f |
|
352 | couldn't find merge tool true specified for f | |
353 | merging f |
|
353 | merging f | |
354 | merging f failed! |
|
354 | merging f failed! | |
355 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
355 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
356 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
356 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
357 | [1] |
|
357 | [1] | |
358 | $ aftermerge |
|
358 | $ aftermerge | |
359 | # cat f |
|
359 | # cat f | |
360 | revision 1 |
|
360 | revision 1 | |
361 | space |
|
361 | space | |
362 | # hg stat |
|
362 | # hg stat | |
363 | M f |
|
363 | M f | |
364 | ? f.orig |
|
364 | ? f.orig | |
365 |
|
365 | |||
366 | merge-patterns specifies executable with bogus path and gets warning: |
|
366 | merge-patterns specifies executable with bogus path and gets warning: | |
367 |
|
367 | |||
368 | $ beforemerge |
|
368 | $ beforemerge | |
369 | [merge-tools] |
|
369 | [merge-tools] | |
370 | false.whatever= |
|
370 | false.whatever= | |
371 | true.priority=1 |
|
371 | true.priority=1 | |
372 | true.executable=cat |
|
372 | true.executable=cat | |
373 | # hg update -C 1 |
|
373 | # hg update -C 1 | |
374 | $ hg merge -r 2 --config merge-patterns.f=true --config merge-tools.true.executable=/nonexistent/mergetool |
|
374 | $ hg merge -r 2 --config merge-patterns.f=true --config merge-tools.true.executable=/nonexistent/mergetool | |
375 | couldn't find merge tool true specified for f |
|
375 | couldn't find merge tool true specified for f | |
376 | merging f |
|
376 | merging f | |
377 | merging f failed! |
|
377 | merging f failed! | |
378 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
378 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
379 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
379 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
380 | [1] |
|
380 | [1] | |
381 | $ aftermerge |
|
381 | $ aftermerge | |
382 | # cat f |
|
382 | # cat f | |
383 | revision 1 |
|
383 | revision 1 | |
384 | space |
|
384 | space | |
385 | # hg stat |
|
385 | # hg stat | |
386 | M f |
|
386 | M f | |
387 | ? f.orig |
|
387 | ? f.orig | |
388 |
|
388 | |||
389 | ui.merge overrules priority |
|
389 | ui.merge overrules priority | |
390 |
|
390 | |||
391 | ui.merge specifies false: |
|
391 | ui.merge specifies false: | |
392 |
|
392 | |||
393 | $ beforemerge |
|
393 | $ beforemerge | |
394 | [merge-tools] |
|
394 | [merge-tools] | |
395 | false.whatever= |
|
395 | false.whatever= | |
396 | true.priority=1 |
|
396 | true.priority=1 | |
397 | true.executable=cat |
|
397 | true.executable=cat | |
398 | # hg update -C 1 |
|
398 | # hg update -C 1 | |
399 | $ hg merge -r 2 --config ui.merge=false |
|
399 | $ hg merge -r 2 --config ui.merge=false | |
400 | merging f |
|
400 | merging f | |
401 | merging f failed! |
|
401 | merging f failed! | |
402 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
402 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
403 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
403 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
404 | [1] |
|
404 | [1] | |
405 | $ aftermerge |
|
405 | $ aftermerge | |
406 | # cat f |
|
406 | # cat f | |
407 | revision 1 |
|
407 | revision 1 | |
408 | space |
|
408 | space | |
409 | # hg stat |
|
409 | # hg stat | |
410 | M f |
|
410 | M f | |
411 | ? f.orig |
|
411 | ? f.orig | |
412 |
|
412 | |||
413 | ui.merge specifies internal:fail: |
|
413 | ui.merge specifies internal:fail: | |
414 |
|
414 | |||
415 | $ beforemerge |
|
415 | $ beforemerge | |
416 | [merge-tools] |
|
416 | [merge-tools] | |
417 | false.whatever= |
|
417 | false.whatever= | |
418 | true.priority=1 |
|
418 | true.priority=1 | |
419 | true.executable=cat |
|
419 | true.executable=cat | |
420 | # hg update -C 1 |
|
420 | # hg update -C 1 | |
421 | $ hg merge -r 2 --config ui.merge=internal:fail |
|
421 | $ hg merge -r 2 --config ui.merge=internal:fail | |
422 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
422 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
423 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
423 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
424 | [1] |
|
424 | [1] | |
425 | $ aftermerge |
|
425 | $ aftermerge | |
426 | # cat f |
|
426 | # cat f | |
427 | revision 1 |
|
427 | revision 1 | |
428 | space |
|
428 | space | |
429 | # hg stat |
|
429 | # hg stat | |
430 | M f |
|
430 | M f | |
431 |
|
431 | |||
432 | ui.merge specifies :local (without internal prefix): |
|
432 | ui.merge specifies :local (without internal prefix): | |
433 |
|
433 | |||
434 | $ beforemerge |
|
434 | $ beforemerge | |
435 | [merge-tools] |
|
435 | [merge-tools] | |
436 | false.whatever= |
|
436 | false.whatever= | |
437 | true.priority=1 |
|
437 | true.priority=1 | |
438 | true.executable=cat |
|
438 | true.executable=cat | |
439 | # hg update -C 1 |
|
439 | # hg update -C 1 | |
440 | $ hg merge -r 2 --config ui.merge=:local |
|
440 | $ hg merge -r 2 --config ui.merge=:local | |
441 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
441 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
442 | (branch merge, don't forget to commit) |
|
442 | (branch merge, don't forget to commit) | |
443 | $ aftermerge |
|
443 | $ aftermerge | |
444 | # cat f |
|
444 | # cat f | |
445 | revision 1 |
|
445 | revision 1 | |
446 | space |
|
446 | space | |
447 | # hg stat |
|
447 | # hg stat | |
448 | M f |
|
448 | M f | |
449 |
|
449 | |||
450 | ui.merge specifies internal:other: |
|
450 | ui.merge specifies internal:other: | |
451 |
|
451 | |||
452 | $ beforemerge |
|
452 | $ beforemerge | |
453 | [merge-tools] |
|
453 | [merge-tools] | |
454 | false.whatever= |
|
454 | false.whatever= | |
455 | true.priority=1 |
|
455 | true.priority=1 | |
456 | true.executable=cat |
|
456 | true.executable=cat | |
457 | # hg update -C 1 |
|
457 | # hg update -C 1 | |
458 | $ hg merge -r 2 --config ui.merge=internal:other |
|
458 | $ hg merge -r 2 --config ui.merge=internal:other | |
459 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
459 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
460 | (branch merge, don't forget to commit) |
|
460 | (branch merge, don't forget to commit) | |
461 | $ aftermerge |
|
461 | $ aftermerge | |
462 | # cat f |
|
462 | # cat f | |
463 | revision 2 |
|
463 | revision 2 | |
464 | space |
|
464 | space | |
465 | # hg stat |
|
465 | # hg stat | |
466 | M f |
|
466 | M f | |
467 |
|
467 | |||
468 | ui.merge specifies internal:prompt: |
|
468 | ui.merge specifies internal:prompt: | |
469 |
|
469 | |||
470 | $ beforemerge |
|
470 | $ beforemerge | |
471 | [merge-tools] |
|
471 | [merge-tools] | |
472 | false.whatever= |
|
472 | false.whatever= | |
473 | true.priority=1 |
|
473 | true.priority=1 | |
474 | true.executable=cat |
|
474 | true.executable=cat | |
475 | # hg update -C 1 |
|
475 | # hg update -C 1 | |
476 | $ hg merge -r 2 --config ui.merge=internal:prompt |
|
476 | $ hg merge -r 2 --config ui.merge=internal:prompt | |
477 | no tool found to merge f |
|
477 | no tool found to merge f | |
478 | keep (l)ocal or take (o)ther? l |
|
478 | keep (l)ocal or take (o)ther? l | |
479 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
479 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
480 | (branch merge, don't forget to commit) |
|
480 | (branch merge, don't forget to commit) | |
481 | $ aftermerge |
|
481 | $ aftermerge | |
482 | # cat f |
|
482 | # cat f | |
483 | revision 1 |
|
483 | revision 1 | |
484 | space |
|
484 | space | |
485 | # hg stat |
|
485 | # hg stat | |
486 | M f |
|
486 | M f | |
487 |
|
487 | |||
488 | ui.merge specifies internal:dump: |
|
488 | ui.merge specifies internal:dump: | |
489 |
|
489 | |||
490 | $ beforemerge |
|
490 | $ beforemerge | |
491 | [merge-tools] |
|
491 | [merge-tools] | |
492 | false.whatever= |
|
492 | false.whatever= | |
493 | true.priority=1 |
|
493 | true.priority=1 | |
494 | true.executable=cat |
|
494 | true.executable=cat | |
495 | # hg update -C 1 |
|
495 | # hg update -C 1 | |
496 | $ hg merge -r 2 --config ui.merge=internal:dump |
|
496 | $ hg merge -r 2 --config ui.merge=internal:dump | |
497 | merging f |
|
497 | merging f | |
498 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
498 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
499 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
499 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
500 | [1] |
|
500 | [1] | |
501 | $ aftermerge |
|
501 | $ aftermerge | |
502 | # cat f |
|
502 | # cat f | |
503 | revision 1 |
|
503 | revision 1 | |
504 | space |
|
504 | space | |
505 | # hg stat |
|
505 | # hg stat | |
506 | M f |
|
506 | M f | |
507 | ? f.base |
|
507 | ? f.base | |
508 | ? f.local |
|
508 | ? f.local | |
509 | ? f.orig |
|
509 | ? f.orig | |
510 | ? f.other |
|
510 | ? f.other | |
511 |
|
511 | |||
512 | f.base: |
|
512 | f.base: | |
513 |
|
513 | |||
514 | $ cat f.base |
|
514 | $ cat f.base | |
515 | revision 0 |
|
515 | revision 0 | |
516 | space |
|
516 | space | |
517 |
|
517 | |||
518 | f.local: |
|
518 | f.local: | |
519 |
|
519 | |||
520 | $ cat f.local |
|
520 | $ cat f.local | |
521 | revision 1 |
|
521 | revision 1 | |
522 | space |
|
522 | space | |
523 |
|
523 | |||
524 | f.other: |
|
524 | f.other: | |
525 |
|
525 | |||
526 | $ cat f.other |
|
526 | $ cat f.other | |
527 | revision 2 |
|
527 | revision 2 | |
528 | space |
|
528 | space | |
529 | $ rm f.base f.local f.other |
|
529 | $ rm f.base f.local f.other | |
530 |
|
530 | |||
531 | ui.merge specifies internal:other but is overruled by pattern for false: |
|
531 | ui.merge specifies internal:other but is overruled by pattern for false: | |
532 |
|
532 | |||
533 | $ beforemerge |
|
533 | $ beforemerge | |
534 | [merge-tools] |
|
534 | [merge-tools] | |
535 | false.whatever= |
|
535 | false.whatever= | |
536 | true.priority=1 |
|
536 | true.priority=1 | |
537 | true.executable=cat |
|
537 | true.executable=cat | |
538 | # hg update -C 1 |
|
538 | # hg update -C 1 | |
539 | $ hg merge -r 2 --config ui.merge=internal:other --config merge-patterns.f=false |
|
539 | $ hg merge -r 2 --config ui.merge=internal:other --config merge-patterns.f=false | |
540 | merging f |
|
540 | merging f | |
541 | merging f failed! |
|
541 | merging f failed! | |
542 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
542 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
543 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
543 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
544 | [1] |
|
544 | [1] | |
545 | $ aftermerge |
|
545 | $ aftermerge | |
546 | # cat f |
|
546 | # cat f | |
547 | revision 1 |
|
547 | revision 1 | |
548 | space |
|
548 | space | |
549 | # hg stat |
|
549 | # hg stat | |
550 | M f |
|
550 | M f | |
551 | ? f.orig |
|
551 | ? f.orig | |
552 |
|
552 | |||
553 | Premerge |
|
553 | Premerge | |
554 |
|
554 | |||
555 | ui.merge specifies internal:other but is overruled by --tool=false |
|
555 | ui.merge specifies internal:other but is overruled by --tool=false | |
556 |
|
556 | |||
557 | $ beforemerge |
|
557 | $ beforemerge | |
558 | [merge-tools] |
|
558 | [merge-tools] | |
559 | false.whatever= |
|
559 | false.whatever= | |
560 | true.priority=1 |
|
560 | true.priority=1 | |
561 | true.executable=cat |
|
561 | true.executable=cat | |
562 | # hg update -C 1 |
|
562 | # hg update -C 1 | |
563 | $ hg merge -r 2 --config ui.merge=internal:other --tool=false |
|
563 | $ hg merge -r 2 --config ui.merge=internal:other --tool=false | |
564 | merging f |
|
564 | merging f | |
565 | merging f failed! |
|
565 | merging f failed! | |
566 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
566 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
567 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
567 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
568 | [1] |
|
568 | [1] | |
569 | $ aftermerge |
|
569 | $ aftermerge | |
570 | # cat f |
|
570 | # cat f | |
571 | revision 1 |
|
571 | revision 1 | |
572 | space |
|
572 | space | |
573 | # hg stat |
|
573 | # hg stat | |
574 | M f |
|
574 | M f | |
575 | ? f.orig |
|
575 | ? f.orig | |
576 |
|
576 | |||
577 | HGMERGE specifies internal:other but is overruled by --tool=false |
|
577 | HGMERGE specifies internal:other but is overruled by --tool=false | |
578 |
|
578 | |||
579 | $ HGMERGE=internal:other ; export HGMERGE |
|
579 | $ HGMERGE=internal:other ; export HGMERGE | |
580 | $ beforemerge |
|
580 | $ beforemerge | |
581 | [merge-tools] |
|
581 | [merge-tools] | |
582 | false.whatever= |
|
582 | false.whatever= | |
583 | true.priority=1 |
|
583 | true.priority=1 | |
584 | true.executable=cat |
|
584 | true.executable=cat | |
585 | # hg update -C 1 |
|
585 | # hg update -C 1 | |
586 | $ hg merge -r 2 --tool=false |
|
586 | $ hg merge -r 2 --tool=false | |
587 | merging f |
|
587 | merging f | |
588 | merging f failed! |
|
588 | merging f failed! | |
589 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
589 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
590 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
590 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
591 | [1] |
|
591 | [1] | |
592 | $ aftermerge |
|
592 | $ aftermerge | |
593 | # cat f |
|
593 | # cat f | |
594 | revision 1 |
|
594 | revision 1 | |
595 | space |
|
595 | space | |
596 | # hg stat |
|
596 | # hg stat | |
597 | M f |
|
597 | M f | |
598 | ? f.orig |
|
598 | ? f.orig | |
599 |
|
599 | |||
600 | $ unset HGMERGE # make sure HGMERGE doesn't interfere with remaining tests |
|
600 | $ unset HGMERGE # make sure HGMERGE doesn't interfere with remaining tests | |
601 |
|
601 | |||
602 | update is a merge ... |
|
602 | update is a merge ... | |
603 |
|
603 | |||
604 | (this also tests that files reverted with '--rev REV' are treated as |
|
604 | (this also tests that files reverted with '--rev REV' are treated as | |
605 | "modified", even if none of mode, size and timestamp of them isn't |
|
605 | "modified", even if none of mode, size and timestamp of them isn't | |
606 | changed on the filesystem (see also issue4583)) |
|
606 | changed on the filesystem (see also issue4583)) | |
607 |
|
607 | |||
608 | $ cat >> $HGRCPATH <<EOF |
|
608 | $ cat >> $HGRCPATH <<EOF | |
609 | > [fakedirstatewritetime] |
|
609 | > [fakedirstatewritetime] | |
610 | > # emulate invoking dirstate.write() via repo.status() |
|
610 | > # emulate invoking dirstate.write() via repo.status() | |
611 | > # at 2000-01-01 00:00 |
|
611 | > # at 2000-01-01 00:00 | |
612 | > fakenow = 200001010000 |
|
612 | > fakenow = 200001010000 | |
613 | > EOF |
|
613 | > EOF | |
614 |
|
614 | |||
615 | $ beforemerge |
|
615 | $ beforemerge | |
616 | [merge-tools] |
|
616 | [merge-tools] | |
617 | false.whatever= |
|
617 | false.whatever= | |
618 | true.priority=1 |
|
618 | true.priority=1 | |
619 | true.executable=cat |
|
619 | true.executable=cat | |
620 | # hg update -C 1 |
|
620 | # hg update -C 1 | |
621 | $ hg update -q 0 |
|
621 | $ hg update -q 0 | |
622 | $ f -s f |
|
622 | $ f -s f | |
623 | f: size=17 |
|
623 | f: size=17 | |
624 | $ touch -t 200001010000 f |
|
624 | $ touch -t 200001010000 f | |
625 | $ hg debugrebuildstate |
|
625 | $ hg debugrebuildstate | |
626 | $ cat >> $HGRCPATH <<EOF |
|
626 | $ cat >> $HGRCPATH <<EOF | |
627 | > [extensions] |
|
627 | > [extensions] | |
628 | > fakedirstatewritetime = $TESTDIR/fakedirstatewritetime.py |
|
628 | > fakedirstatewritetime = $TESTDIR/fakedirstatewritetime.py | |
629 | > EOF |
|
629 | > EOF | |
630 | $ hg revert -q -r 1 . |
|
630 | $ hg revert -q -r 1 . | |
631 | $ cat >> $HGRCPATH <<EOF |
|
631 | $ cat >> $HGRCPATH <<EOF | |
632 | > [extensions] |
|
632 | > [extensions] | |
633 | > fakedirstatewritetime = ! |
|
633 | > fakedirstatewritetime = ! | |
634 | > EOF |
|
634 | > EOF | |
635 | $ f -s f |
|
635 | $ f -s f | |
636 | f: size=17 |
|
636 | f: size=17 | |
637 | $ touch -t 200001010000 f |
|
637 | $ touch -t 200001010000 f | |
638 | $ hg status f |
|
638 | $ hg status f | |
639 | M f |
|
639 | M f | |
640 | $ hg update -r 2 |
|
640 | $ hg update -r 2 | |
641 | merging f |
|
641 | merging f | |
642 | revision 1 |
|
642 | revision 1 | |
643 | space |
|
643 | space | |
644 | revision 0 |
|
644 | revision 0 | |
645 | space |
|
645 | space | |
646 | revision 2 |
|
646 | revision 2 | |
647 | space |
|
647 | space | |
648 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
648 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
649 | $ aftermerge |
|
649 | $ aftermerge | |
650 | # cat f |
|
650 | # cat f | |
651 | revision 1 |
|
651 | revision 1 | |
652 | space |
|
652 | space | |
653 | # hg stat |
|
653 | # hg stat | |
654 | M f |
|
654 | M f | |
655 |
|
655 | |||
656 | update should also have --tool |
|
656 | update should also have --tool | |
657 |
|
657 | |||
658 | $ beforemerge |
|
658 | $ beforemerge | |
659 | [merge-tools] |
|
659 | [merge-tools] | |
660 | false.whatever= |
|
660 | false.whatever= | |
661 | true.priority=1 |
|
661 | true.priority=1 | |
662 | true.executable=cat |
|
662 | true.executable=cat | |
663 | # hg update -C 1 |
|
663 | # hg update -C 1 | |
664 | $ hg update -q 0 |
|
664 | $ hg update -q 0 | |
665 | $ f -s f |
|
665 | $ f -s f | |
666 | f: size=17 |
|
666 | f: size=17 | |
667 | $ touch -t 200001010000 f |
|
667 | $ touch -t 200001010000 f | |
668 | $ hg debugrebuildstate |
|
668 | $ hg debugrebuildstate | |
669 | $ cat >> $HGRCPATH <<EOF |
|
669 | $ cat >> $HGRCPATH <<EOF | |
670 | > [extensions] |
|
670 | > [extensions] | |
671 | > fakedirstatewritetime = $TESTDIR/fakedirstatewritetime.py |
|
671 | > fakedirstatewritetime = $TESTDIR/fakedirstatewritetime.py | |
672 | > EOF |
|
672 | > EOF | |
673 | $ hg revert -q -r 1 . |
|
673 | $ hg revert -q -r 1 . | |
674 | $ cat >> $HGRCPATH <<EOF |
|
674 | $ cat >> $HGRCPATH <<EOF | |
675 | > [extensions] |
|
675 | > [extensions] | |
676 | > fakedirstatewritetime = ! |
|
676 | > fakedirstatewritetime = ! | |
677 | > EOF |
|
677 | > EOF | |
678 | $ f -s f |
|
678 | $ f -s f | |
679 | f: size=17 |
|
679 | f: size=17 | |
680 | $ touch -t 200001010000 f |
|
680 | $ touch -t 200001010000 f | |
681 | $ hg status f |
|
681 | $ hg status f | |
682 | M f |
|
682 | M f | |
683 | $ hg update -r 2 --tool false |
|
683 | $ hg update -r 2 --tool false | |
684 | merging f |
|
684 | merging f | |
685 | merging f failed! |
|
685 | merging f failed! | |
686 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
686 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
687 | use 'hg resolve' to retry unresolved file merges |
|
687 | use 'hg resolve' to retry unresolved file merges | |
688 | [1] |
|
688 | [1] | |
689 | $ aftermerge |
|
689 | $ aftermerge | |
690 | # cat f |
|
690 | # cat f | |
691 | revision 1 |
|
691 | revision 1 | |
692 | space |
|
692 | space | |
693 | # hg stat |
|
693 | # hg stat | |
694 | M f |
|
694 | M f | |
695 | ? f.orig |
|
695 | ? f.orig | |
696 |
|
696 | |||
697 | Default is silent simplemerge: |
|
697 | Default is silent simplemerge: | |
698 |
|
698 | |||
699 | $ beforemerge |
|
699 | $ beforemerge | |
700 | [merge-tools] |
|
700 | [merge-tools] | |
701 | false.whatever= |
|
701 | false.whatever= | |
702 | true.priority=1 |
|
702 | true.priority=1 | |
703 | true.executable=cat |
|
703 | true.executable=cat | |
704 | # hg update -C 1 |
|
704 | # hg update -C 1 | |
705 | $ hg merge -r 3 |
|
705 | $ hg merge -r 3 | |
706 | merging f |
|
706 | merging f | |
707 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
707 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
708 | (branch merge, don't forget to commit) |
|
708 | (branch merge, don't forget to commit) | |
709 | $ aftermerge |
|
709 | $ aftermerge | |
710 | # cat f |
|
710 | # cat f | |
711 | revision 1 |
|
711 | revision 1 | |
712 | space |
|
712 | space | |
713 | revision 3 |
|
713 | revision 3 | |
714 | # hg stat |
|
714 | # hg stat | |
715 | M f |
|
715 | M f | |
716 |
|
716 | |||
717 | .premerge=True is same: |
|
717 | .premerge=True is same: | |
718 |
|
718 | |||
719 | $ beforemerge |
|
719 | $ beforemerge | |
720 | [merge-tools] |
|
720 | [merge-tools] | |
721 | false.whatever= |
|
721 | false.whatever= | |
722 | true.priority=1 |
|
722 | true.priority=1 | |
723 | true.executable=cat |
|
723 | true.executable=cat | |
724 | # hg update -C 1 |
|
724 | # hg update -C 1 | |
725 | $ hg merge -r 3 --config merge-tools.true.premerge=True |
|
725 | $ hg merge -r 3 --config merge-tools.true.premerge=True | |
726 | merging f |
|
726 | merging f | |
727 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
727 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
728 | (branch merge, don't forget to commit) |
|
728 | (branch merge, don't forget to commit) | |
729 | $ aftermerge |
|
729 | $ aftermerge | |
730 | # cat f |
|
730 | # cat f | |
731 | revision 1 |
|
731 | revision 1 | |
732 | space |
|
732 | space | |
733 | revision 3 |
|
733 | revision 3 | |
734 | # hg stat |
|
734 | # hg stat | |
735 | M f |
|
735 | M f | |
736 |
|
736 | |||
737 | .premerge=False executes merge-tool: |
|
737 | .premerge=False executes merge-tool: | |
738 |
|
738 | |||
739 | $ beforemerge |
|
739 | $ beforemerge | |
740 | [merge-tools] |
|
740 | [merge-tools] | |
741 | false.whatever= |
|
741 | false.whatever= | |
742 | true.priority=1 |
|
742 | true.priority=1 | |
743 | true.executable=cat |
|
743 | true.executable=cat | |
744 | # hg update -C 1 |
|
744 | # hg update -C 1 | |
745 | $ hg merge -r 3 --config merge-tools.true.premerge=False |
|
745 | $ hg merge -r 3 --config merge-tools.true.premerge=False | |
746 | merging f |
|
746 | merging f | |
747 | revision 1 |
|
747 | revision 1 | |
748 | space |
|
748 | space | |
749 | revision 0 |
|
749 | revision 0 | |
750 | space |
|
750 | space | |
751 | revision 0 |
|
751 | revision 0 | |
752 | space |
|
752 | space | |
753 | revision 3 |
|
753 | revision 3 | |
754 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
754 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
755 | (branch merge, don't forget to commit) |
|
755 | (branch merge, don't forget to commit) | |
756 | $ aftermerge |
|
756 | $ aftermerge | |
757 | # cat f |
|
757 | # cat f | |
758 | revision 1 |
|
758 | revision 1 | |
759 | space |
|
759 | space | |
760 | # hg stat |
|
760 | # hg stat | |
761 | M f |
|
761 | M f | |
762 |
|
762 | |||
763 | premerge=keep keeps conflict markers in: |
|
763 | premerge=keep keeps conflict markers in: | |
764 |
|
764 | |||
765 | $ beforemerge |
|
765 | $ beforemerge | |
766 | [merge-tools] |
|
766 | [merge-tools] | |
767 | false.whatever= |
|
767 | false.whatever= | |
768 | true.priority=1 |
|
768 | true.priority=1 | |
769 | true.executable=cat |
|
769 | true.executable=cat | |
770 | # hg update -C 1 |
|
770 | # hg update -C 1 | |
771 | $ hg merge -r 4 --config merge-tools.true.premerge=keep |
|
771 | $ hg merge -r 4 --config merge-tools.true.premerge=keep | |
772 | merging f |
|
772 | merging f | |
773 | <<<<<<< local: ef83787e2614 - test: revision 1 |
|
773 | <<<<<<< local: ef83787e2614 - test: revision 1 | |
774 | revision 1 |
|
774 | revision 1 | |
775 | space |
|
775 | space | |
776 | ======= |
|
776 | ======= | |
777 | revision 4 |
|
777 | revision 4 | |
778 | >>>>>>> other: 81448d39c9a0 - test: revision 4 |
|
778 | >>>>>>> other: 81448d39c9a0 - test: revision 4 | |
779 | revision 0 |
|
779 | revision 0 | |
780 | space |
|
780 | space | |
781 | revision 4 |
|
781 | revision 4 | |
782 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
782 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
783 | (branch merge, don't forget to commit) |
|
783 | (branch merge, don't forget to commit) | |
784 | $ aftermerge |
|
784 | $ aftermerge | |
785 | # cat f |
|
785 | # cat f | |
786 | <<<<<<< local: ef83787e2614 - test: revision 1 |
|
786 | <<<<<<< local: ef83787e2614 - test: revision 1 | |
787 | revision 1 |
|
787 | revision 1 | |
788 | space |
|
788 | space | |
789 | ======= |
|
789 | ======= | |
790 | revision 4 |
|
790 | revision 4 | |
791 | >>>>>>> other: 81448d39c9a0 - test: revision 4 |
|
791 | >>>>>>> other: 81448d39c9a0 - test: revision 4 | |
792 | # hg stat |
|
792 | # hg stat | |
793 | M f |
|
793 | M f | |
794 |
|
794 | |||
795 | premerge=keep-merge3 keeps conflict markers with base content: |
|
795 | premerge=keep-merge3 keeps conflict markers with base content: | |
796 |
|
796 | |||
797 | $ beforemerge |
|
797 | $ beforemerge | |
798 | [merge-tools] |
|
798 | [merge-tools] | |
799 | false.whatever= |
|
799 | false.whatever= | |
800 | true.priority=1 |
|
800 | true.priority=1 | |
801 | true.executable=cat |
|
801 | true.executable=cat | |
802 | # hg update -C 1 |
|
802 | # hg update -C 1 | |
803 | $ hg merge -r 4 --config merge-tools.true.premerge=keep-merge3 |
|
803 | $ hg merge -r 4 --config merge-tools.true.premerge=keep-merge3 | |
804 | merging f |
|
804 | merging f | |
805 | <<<<<<< local: ef83787e2614 - test: revision 1 |
|
805 | <<<<<<< local: ef83787e2614 - test: revision 1 | |
806 | revision 1 |
|
806 | revision 1 | |
807 | space |
|
807 | space | |
808 | ||||||| base |
|
808 | ||||||| base | |
809 | revision 0 |
|
809 | revision 0 | |
810 | space |
|
810 | space | |
811 | ======= |
|
811 | ======= | |
812 | revision 4 |
|
812 | revision 4 | |
813 | >>>>>>> other: 81448d39c9a0 - test: revision 4 |
|
813 | >>>>>>> other: 81448d39c9a0 - test: revision 4 | |
814 | revision 0 |
|
814 | revision 0 | |
815 | space |
|
815 | space | |
816 | revision 4 |
|
816 | revision 4 | |
817 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
817 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
818 | (branch merge, don't forget to commit) |
|
818 | (branch merge, don't forget to commit) | |
819 | $ aftermerge |
|
819 | $ aftermerge | |
820 | # cat f |
|
820 | # cat f | |
821 | <<<<<<< local: ef83787e2614 - test: revision 1 |
|
821 | <<<<<<< local: ef83787e2614 - test: revision 1 | |
822 | revision 1 |
|
822 | revision 1 | |
823 | space |
|
823 | space | |
824 | ||||||| base |
|
824 | ||||||| base | |
825 | revision 0 |
|
825 | revision 0 | |
826 | space |
|
826 | space | |
827 | ======= |
|
827 | ======= | |
828 | revision 4 |
|
828 | revision 4 | |
829 | >>>>>>> other: 81448d39c9a0 - test: revision 4 |
|
829 | >>>>>>> other: 81448d39c9a0 - test: revision 4 | |
830 | # hg stat |
|
830 | # hg stat | |
831 | M f |
|
831 | M f | |
832 |
|
832 | |||
833 |
|
833 | |||
834 | Tool execution |
|
834 | Tool execution | |
835 |
|
835 | |||
836 | set tools.args explicit to include $base $local $other $output: |
|
836 | set tools.args explicit to include $base $local $other $output: | |
837 |
|
837 | |||
838 | $ beforemerge |
|
838 | $ beforemerge | |
839 | [merge-tools] |
|
839 | [merge-tools] | |
840 | false.whatever= |
|
840 | false.whatever= | |
841 | true.priority=1 |
|
841 | true.priority=1 | |
842 | true.executable=cat |
|
842 | true.executable=cat | |
843 | # hg update -C 1 |
|
843 | # hg update -C 1 | |
844 | $ hg merge -r 2 --config merge-tools.true.executable=head --config merge-tools.true.args='$base $local $other $output' \ |
|
844 | $ hg merge -r 2 --config merge-tools.true.executable=head --config merge-tools.true.args='$base $local $other $output' \ | |
845 | > | sed 's,==> .* <==,==> ... <==,g' |
|
845 | > | sed 's,==> .* <==,==> ... <==,g' | |
846 | merging f |
|
846 | merging f | |
847 | ==> ... <== |
|
847 | ==> ... <== | |
848 | revision 0 |
|
848 | revision 0 | |
849 | space |
|
849 | space | |
850 |
|
850 | |||
851 | ==> ... <== |
|
851 | ==> ... <== | |
852 | revision 1 |
|
852 | revision 1 | |
853 | space |
|
853 | space | |
854 |
|
854 | |||
855 | ==> ... <== |
|
855 | ==> ... <== | |
856 | revision 2 |
|
856 | revision 2 | |
857 | space |
|
857 | space | |
858 |
|
858 | |||
859 | ==> ... <== |
|
859 | ==> ... <== | |
860 | revision 1 |
|
860 | revision 1 | |
861 | space |
|
861 | space | |
862 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
862 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
863 | (branch merge, don't forget to commit) |
|
863 | (branch merge, don't forget to commit) | |
864 | $ aftermerge |
|
864 | $ aftermerge | |
865 | # cat f |
|
865 | # cat f | |
866 | revision 1 |
|
866 | revision 1 | |
867 | space |
|
867 | space | |
868 | # hg stat |
|
868 | # hg stat | |
869 | M f |
|
869 | M f | |
870 |
|
870 | |||
871 | Merge with "echo mergeresult > $local": |
|
871 | Merge with "echo mergeresult > $local": | |
872 |
|
872 | |||
873 | $ beforemerge |
|
873 | $ beforemerge | |
874 | [merge-tools] |
|
874 | [merge-tools] | |
875 | false.whatever= |
|
875 | false.whatever= | |
876 | true.priority=1 |
|
876 | true.priority=1 | |
877 | true.executable=cat |
|
877 | true.executable=cat | |
878 | # hg update -C 1 |
|
878 | # hg update -C 1 | |
879 | $ hg merge -r 2 --config merge-tools.true.executable=echo --config merge-tools.true.args='mergeresult > $local' |
|
879 | $ hg merge -r 2 --config merge-tools.true.executable=echo --config merge-tools.true.args='mergeresult > $local' | |
880 | merging f |
|
880 | merging f | |
881 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
881 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
882 | (branch merge, don't forget to commit) |
|
882 | (branch merge, don't forget to commit) | |
883 | $ aftermerge |
|
883 | $ aftermerge | |
884 | # cat f |
|
884 | # cat f | |
885 | mergeresult |
|
885 | mergeresult | |
886 | # hg stat |
|
886 | # hg stat | |
887 | M f |
|
887 | M f | |
888 |
|
888 | |||
889 | - and $local is the file f: |
|
889 | - and $local is the file f: | |
890 |
|
890 | |||
891 | $ beforemerge |
|
891 | $ beforemerge | |
892 | [merge-tools] |
|
892 | [merge-tools] | |
893 | false.whatever= |
|
893 | false.whatever= | |
894 | true.priority=1 |
|
894 | true.priority=1 | |
895 | true.executable=cat |
|
895 | true.executable=cat | |
896 | # hg update -C 1 |
|
896 | # hg update -C 1 | |
897 | $ hg merge -r 2 --config merge-tools.true.executable=echo --config merge-tools.true.args='mergeresult > f' |
|
897 | $ hg merge -r 2 --config merge-tools.true.executable=echo --config merge-tools.true.args='mergeresult > f' | |
898 | merging f |
|
898 | merging f | |
899 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
899 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
900 | (branch merge, don't forget to commit) |
|
900 | (branch merge, don't forget to commit) | |
901 | $ aftermerge |
|
901 | $ aftermerge | |
902 | # cat f |
|
902 | # cat f | |
903 | mergeresult |
|
903 | mergeresult | |
904 | # hg stat |
|
904 | # hg stat | |
905 | M f |
|
905 | M f | |
906 |
|
906 | |||
907 | Merge with "echo mergeresult > $output" - the variable is a bit magic: |
|
907 | Merge with "echo mergeresult > $output" - the variable is a bit magic: | |
908 |
|
908 | |||
909 | $ beforemerge |
|
909 | $ beforemerge | |
910 | [merge-tools] |
|
910 | [merge-tools] | |
911 | false.whatever= |
|
911 | false.whatever= | |
912 | true.priority=1 |
|
912 | true.priority=1 | |
913 | true.executable=cat |
|
913 | true.executable=cat | |
914 | # hg update -C 1 |
|
914 | # hg update -C 1 | |
915 | $ hg merge -r 2 --config merge-tools.true.executable=echo --config merge-tools.true.args='mergeresult > $output' |
|
915 | $ hg merge -r 2 --config merge-tools.true.executable=echo --config merge-tools.true.args='mergeresult > $output' | |
916 | merging f |
|
916 | merging f | |
917 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
917 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
918 | (branch merge, don't forget to commit) |
|
918 | (branch merge, don't forget to commit) | |
919 | $ aftermerge |
|
919 | $ aftermerge | |
920 | # cat f |
|
920 | # cat f | |
921 | mergeresult |
|
921 | mergeresult | |
922 | # hg stat |
|
922 | # hg stat | |
923 | M f |
|
923 | M f | |
924 |
|
924 | |||
925 | Merge using tool with a path that must be quoted: |
|
925 | Merge using tool with a path that must be quoted: | |
926 |
|
926 | |||
927 | $ beforemerge |
|
927 | $ beforemerge | |
928 | [merge-tools] |
|
928 | [merge-tools] | |
929 | false.whatever= |
|
929 | false.whatever= | |
930 | true.priority=1 |
|
930 | true.priority=1 | |
931 | true.executable=cat |
|
931 | true.executable=cat | |
932 | # hg update -C 1 |
|
932 | # hg update -C 1 | |
933 | $ cat <<EOF > 'my merge tool' |
|
933 | $ cat <<EOF > 'my merge tool' | |
934 | > cat "\$1" "\$2" "\$3" > "\$4" |
|
934 | > cat "\$1" "\$2" "\$3" > "\$4" | |
935 | > EOF |
|
935 | > EOF | |
936 | $ hg --config merge-tools.true.executable='sh' \ |
|
936 | $ hg --config merge-tools.true.executable='sh' \ | |
937 | > --config merge-tools.true.args='"./my merge tool" $base $local $other $output' \ |
|
937 | > --config merge-tools.true.args='"./my merge tool" $base $local $other $output' \ | |
938 | > merge -r 2 |
|
938 | > merge -r 2 | |
939 | merging f |
|
939 | merging f | |
940 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
940 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
941 | (branch merge, don't forget to commit) |
|
941 | (branch merge, don't forget to commit) | |
942 | $ rm -f 'my merge tool' |
|
942 | $ rm -f 'my merge tool' | |
943 | $ aftermerge |
|
943 | $ aftermerge | |
944 | # cat f |
|
944 | # cat f | |
945 | revision 0 |
|
945 | revision 0 | |
946 | space |
|
946 | space | |
947 | revision 1 |
|
947 | revision 1 | |
948 | space |
|
948 | space | |
949 | revision 2 |
|
949 | revision 2 | |
950 | space |
|
950 | space | |
951 | # hg stat |
|
951 | # hg stat | |
952 | M f |
|
952 | M f | |
953 |
|
953 | |||
954 | Issue3581: Merging a filename that needs to be quoted |
|
954 | Issue3581: Merging a filename that needs to be quoted | |
955 | (This test doesn't work on Windows filesystems even on Linux, so check |
|
955 | (This test doesn't work on Windows filesystems even on Linux, so check | |
956 | for Unix-like permission) |
|
956 | for Unix-like permission) | |
957 |
|
957 | |||
958 | #if unix-permissions |
|
958 | #if unix-permissions | |
959 | $ beforemerge |
|
959 | $ beforemerge | |
960 | [merge-tools] |
|
960 | [merge-tools] | |
961 | false.whatever= |
|
961 | false.whatever= | |
962 | true.priority=1 |
|
962 | true.priority=1 | |
963 | true.executable=cat |
|
963 | true.executable=cat | |
964 | # hg update -C 1 |
|
964 | # hg update -C 1 | |
965 | $ echo "revision 5" > '"; exit 1; echo "' |
|
965 | $ echo "revision 5" > '"; exit 1; echo "' | |
966 | $ hg commit -Am "revision 5" |
|
966 | $ hg commit -Am "revision 5" | |
967 | adding "; exit 1; echo " |
|
967 | adding "; exit 1; echo " | |
968 | warning: filename contains '"', which is reserved on Windows: '"; exit 1; echo "' |
|
968 | warning: filename contains '"', which is reserved on Windows: '"; exit 1; echo "' | |
969 | $ hg update -C 1 > /dev/null |
|
969 | $ hg update -C 1 > /dev/null | |
970 | $ echo "revision 6" > '"; exit 1; echo "' |
|
970 | $ echo "revision 6" > '"; exit 1; echo "' | |
971 | $ hg commit -Am "revision 6" |
|
971 | $ hg commit -Am "revision 6" | |
972 | adding "; exit 1; echo " |
|
972 | adding "; exit 1; echo " | |
973 | warning: filename contains '"', which is reserved on Windows: '"; exit 1; echo "' |
|
973 | warning: filename contains '"', which is reserved on Windows: '"; exit 1; echo "' | |
974 | created new head |
|
974 | created new head | |
975 | $ hg merge --config merge-tools.true.executable="true" -r 5 |
|
975 | $ hg merge --config merge-tools.true.executable="true" -r 5 | |
976 | merging "; exit 1; echo " |
|
976 | merging "; exit 1; echo " | |
977 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
977 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
978 | (branch merge, don't forget to commit) |
|
978 | (branch merge, don't forget to commit) | |
979 | $ hg update -C 1 > /dev/null |
|
979 | $ hg update -C 1 > /dev/null | |
980 | #endif |
|
980 | #endif | |
981 |
|
981 | |||
982 | Merge post-processing |
|
982 | Merge post-processing | |
983 |
|
983 | |||
984 | cat is a bad merge-tool and doesn't change: |
|
984 | cat is a bad merge-tool and doesn't change: | |
985 |
|
985 | |||
986 | $ beforemerge |
|
986 | $ beforemerge | |
987 | [merge-tools] |
|
987 | [merge-tools] | |
988 | false.whatever= |
|
988 | false.whatever= | |
989 | true.priority=1 |
|
989 | true.priority=1 | |
990 | true.executable=cat |
|
990 | true.executable=cat | |
991 | # hg update -C 1 |
|
991 | # hg update -C 1 | |
992 | $ hg merge -y -r 2 --config merge-tools.true.checkchanged=1 |
|
992 | $ hg merge -y -r 2 --config merge-tools.true.checkchanged=1 | |
993 | merging f |
|
993 | merging f | |
994 | revision 1 |
|
994 | revision 1 | |
995 | space |
|
995 | space | |
996 | revision 0 |
|
996 | revision 0 | |
997 | space |
|
997 | space | |
998 | revision 2 |
|
998 | revision 2 | |
999 | space |
|
999 | space | |
1000 | output file f appears unchanged |
|
1000 | output file f appears unchanged | |
1001 | was merge successful (yn)? n |
|
1001 | was merge successful (yn)? n | |
1002 | merging f failed! |
|
1002 | merging f failed! | |
1003 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
1003 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
1004 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
1004 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
1005 | [1] |
|
1005 | [1] | |
1006 | $ aftermerge |
|
1006 | $ aftermerge | |
1007 | # cat f |
|
1007 | # cat f | |
1008 | revision 1 |
|
1008 | revision 1 | |
1009 | space |
|
1009 | space | |
1010 | # hg stat |
|
1010 | # hg stat | |
1011 | M f |
|
1011 | M f | |
1012 | ? f.orig |
|
1012 | ? f.orig | |
1013 |
|
1013 | |||
1014 | #if symlink |
|
1014 | #if symlink | |
1015 |
|
1015 | |||
1016 | internal merge cannot handle symlinks and shouldn't try: |
|
1016 | internal merge cannot handle symlinks and shouldn't try: | |
1017 |
|
1017 | |||
1018 | $ hg update -q -C 1 |
|
1018 | $ hg update -q -C 1 | |
1019 | $ rm f |
|
1019 | $ rm f | |
1020 | $ ln -s symlink f |
|
1020 | $ ln -s symlink f | |
1021 | $ hg commit -qm 'f is symlink' |
|
1021 | $ hg commit -qm 'f is symlink' | |
1022 | $ hg merge -r 2 --tool internal:merge |
|
1022 | $ hg merge -r 2 --tool internal:merge | |
1023 | merging f |
|
1023 | merging f | |
1024 | warning: internal :merge cannot merge symlinks for f |
|
1024 | warning: internal :merge cannot merge symlinks for f | |
1025 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') |
|
1025 | merging f incomplete! (edit conflicts, then use 'hg resolve --mark') | |
1026 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
1026 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
1027 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
1027 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
1028 | [1] |
|
1028 | [1] | |
1029 |
|
1029 | |||
1030 | #endif |
|
1030 | #endif |
General Comments 0
You need to be logged in to leave comments.
Login now