##// END OF EJS Templates
tests: add missing no-outer-repo requirements...
Mads Kiilerich -
r17015:73d20de5 default
parent child Browse files
Show More
@@ -1,426 +1,428 b''
1 $ HGFOO=BAR; export HGFOO
1 $ HGFOO=BAR; export HGFOO
2 $ cat >> $HGRCPATH <<EOF
2 $ cat >> $HGRCPATH <<EOF
3 > [extensions]
3 > [extensions]
4 > graphlog=
4 > graphlog=
5 >
5 >
6 > [alias]
6 > [alias]
7 > # should clobber ci but not commit (issue2993)
7 > # should clobber ci but not commit (issue2993)
8 > ci = version
8 > ci = version
9 > myinit = init
9 > myinit = init
10 > optionalrepo = showconfig alias.myinit
10 > optionalrepo = showconfig alias.myinit
11 > cleanstatus = status -c
11 > cleanstatus = status -c
12 > unknown = bargle
12 > unknown = bargle
13 > ambiguous = s
13 > ambiguous = s
14 > recursive = recursive
14 > recursive = recursive
15 > nodefinition =
15 > nodefinition =
16 > no--cwd = status --cwd elsewhere
16 > no--cwd = status --cwd elsewhere
17 > no-R = status -R elsewhere
17 > no-R = status -R elsewhere
18 > no--repo = status --repo elsewhere
18 > no--repo = status --repo elsewhere
19 > no--repository = status --repository elsewhere
19 > no--repository = status --repository elsewhere
20 > mylog = log
20 > mylog = log
21 > lognull = log -r null
21 > lognull = log -r null
22 > shortlog = log --template '{rev} {node|short} | {date|isodate}\n'
22 > shortlog = log --template '{rev} {node|short} | {date|isodate}\n'
23 > positional = log --template '{\$2} {\$1} | {date|isodate}\n'
23 > positional = log --template '{\$2} {\$1} | {date|isodate}\n'
24 > dln = lognull --debug
24 > dln = lognull --debug
25 > nousage = rollback
25 > nousage = rollback
26 > put = export -r 0 -o "\$FOO/%R.diff"
26 > put = export -r 0 -o "\$FOO/%R.diff"
27 > blank = !printf '\n'
27 > blank = !printf '\n'
28 > self = !printf '\$0\n'
28 > self = !printf '\$0\n'
29 > echoall = !printf '\$@\n'
29 > echoall = !printf '\$@\n'
30 > echo1 = !printf '\$1\n'
30 > echo1 = !printf '\$1\n'
31 > echo2 = !printf '\$2\n'
31 > echo2 = !printf '\$2\n'
32 > echo13 = !printf '\$1 \$3\n'
32 > echo13 = !printf '\$1 \$3\n'
33 > count = !hg log -r "\$@" --template=. | wc -c | sed -e 's/ //g'
33 > count = !hg log -r "\$@" --template=. | wc -c | sed -e 's/ //g'
34 > mcount = !hg log \$@ --template=. | wc -c | sed -e 's/ //g'
34 > mcount = !hg log \$@ --template=. | wc -c | sed -e 's/ //g'
35 > rt = root
35 > rt = root
36 > tglog = glog --template "{rev}:{node|short}: '{desc}' {branches}\n"
36 > tglog = glog --template "{rev}:{node|short}: '{desc}' {branches}\n"
37 > idalias = id
37 > idalias = id
38 > idaliaslong = id
38 > idaliaslong = id
39 > idaliasshell = !echo test
39 > idaliasshell = !echo test
40 > parentsshell1 = !echo one
40 > parentsshell1 = !echo one
41 > parentsshell2 = !echo two
41 > parentsshell2 = !echo two
42 > escaped1 = !printf 'test\$\$test\n'
42 > escaped1 = !printf 'test\$\$test\n'
43 > escaped2 = !sh -c 'echo "HGFOO is \$\$HGFOO"'
43 > escaped2 = !sh -c 'echo "HGFOO is \$\$HGFOO"'
44 > escaped3 = !sh -c 'echo "\$1 is \$\$\$1"'
44 > escaped3 = !sh -c 'echo "\$1 is \$\$\$1"'
45 > escaped4 = !printf '\$\$0 \$\$@\n'
45 > escaped4 = !printf '\$\$0 \$\$@\n'
46 >
46 >
47 > [defaults]
47 > [defaults]
48 > mylog = -q
48 > mylog = -q
49 > lognull = -q
49 > lognull = -q
50 > log = -v
50 > log = -v
51 > EOF
51 > EOF
52
52
53
53
54 basic
54 basic
55
55
56 $ hg myinit alias
56 $ hg myinit alias
57
57
58
58
59 unknown
59 unknown
60
60
61 $ hg unknown
61 $ hg unknown
62 alias 'unknown' resolves to unknown command 'bargle'
62 alias 'unknown' resolves to unknown command 'bargle'
63 $ hg help unknown
63 $ hg help unknown
64 alias 'unknown' resolves to unknown command 'bargle'
64 alias 'unknown' resolves to unknown command 'bargle'
65
65
66
66
67 ambiguous
67 ambiguous
68
68
69 $ hg ambiguous
69 $ hg ambiguous
70 alias 'ambiguous' resolves to ambiguous command 's'
70 alias 'ambiguous' resolves to ambiguous command 's'
71 $ hg help ambiguous
71 $ hg help ambiguous
72 alias 'ambiguous' resolves to ambiguous command 's'
72 alias 'ambiguous' resolves to ambiguous command 's'
73
73
74
74
75 recursive
75 recursive
76
76
77 $ hg recursive
77 $ hg recursive
78 alias 'recursive' resolves to unknown command 'recursive'
78 alias 'recursive' resolves to unknown command 'recursive'
79 $ hg help recursive
79 $ hg help recursive
80 alias 'recursive' resolves to unknown command 'recursive'
80 alias 'recursive' resolves to unknown command 'recursive'
81
81
82
82
83 no definition
83 no definition
84
84
85 $ hg nodef
85 $ hg nodef
86 no definition for alias 'nodefinition'
86 no definition for alias 'nodefinition'
87 $ hg help nodef
87 $ hg help nodef
88 no definition for alias 'nodefinition'
88 no definition for alias 'nodefinition'
89
89
90
90
91 invalid options
91 invalid options
92
92
93 $ hg no--cwd
93 $ hg no--cwd
94 error in definition for alias 'no--cwd': --cwd may only be given on the command line
94 error in definition for alias 'no--cwd': --cwd may only be given on the command line
95 $ hg help no--cwd
95 $ hg help no--cwd
96 error in definition for alias 'no--cwd': --cwd may only be given on the command line
96 error in definition for alias 'no--cwd': --cwd may only be given on the command line
97 $ hg no-R
97 $ hg no-R
98 error in definition for alias 'no-R': -R may only be given on the command line
98 error in definition for alias 'no-R': -R may only be given on the command line
99 $ hg help no-R
99 $ hg help no-R
100 error in definition for alias 'no-R': -R may only be given on the command line
100 error in definition for alias 'no-R': -R may only be given on the command line
101 $ hg no--repo
101 $ hg no--repo
102 error in definition for alias 'no--repo': --repo may only be given on the command line
102 error in definition for alias 'no--repo': --repo may only be given on the command line
103 $ hg help no--repo
103 $ hg help no--repo
104 error in definition for alias 'no--repo': --repo may only be given on the command line
104 error in definition for alias 'no--repo': --repo may only be given on the command line
105 $ hg no--repository
105 $ hg no--repository
106 error in definition for alias 'no--repository': --repository may only be given on the command line
106 error in definition for alias 'no--repository': --repository may only be given on the command line
107 $ hg help no--repository
107 $ hg help no--repository
108 error in definition for alias 'no--repository': --repository may only be given on the command line
108 error in definition for alias 'no--repository': --repository may only be given on the command line
109
109
110 optional repository
110 optional repository
111
111
112 #if no-outer-repo
112 $ hg optionalrepo
113 $ hg optionalrepo
113 init
114 init
115 #endif
114 $ cd alias
116 $ cd alias
115 $ cat > .hg/hgrc <<EOF
117 $ cat > .hg/hgrc <<EOF
116 > [alias]
118 > [alias]
117 > myinit = init -q
119 > myinit = init -q
118 > EOF
120 > EOF
119 $ hg optionalrepo
121 $ hg optionalrepo
120 init -q
122 init -q
121
123
122 no usage
124 no usage
123
125
124 $ hg nousage
126 $ hg nousage
125 no rollback information available
127 no rollback information available
126
128
127 $ echo foo > foo
129 $ echo foo > foo
128 $ hg commit -Amfoo
130 $ hg commit -Amfoo
129 adding foo
131 adding foo
130
132
131
133
132 with opts
134 with opts
133
135
134 $ hg cleanst
136 $ hg cleanst
135 C foo
137 C foo
136
138
137
139
138 with opts and whitespace
140 with opts and whitespace
139
141
140 $ hg shortlog
142 $ hg shortlog
141 0 e63c23eaa88a | 1970-01-01 00:00 +0000
143 0 e63c23eaa88a | 1970-01-01 00:00 +0000
142
144
143 positional arguments
145 positional arguments
144
146
145 $ hg positional
147 $ hg positional
146 abort: too few arguments for command alias
148 abort: too few arguments for command alias
147 [255]
149 [255]
148 $ hg positional a
150 $ hg positional a
149 abort: too few arguments for command alias
151 abort: too few arguments for command alias
150 [255]
152 [255]
151 $ hg positional 'node|short' rev
153 $ hg positional 'node|short' rev
152 0 e63c23eaa88a | 1970-01-01 00:00 +0000
154 0 e63c23eaa88a | 1970-01-01 00:00 +0000
153
155
154 interaction with defaults
156 interaction with defaults
155
157
156 $ hg mylog
158 $ hg mylog
157 0:e63c23eaa88a
159 0:e63c23eaa88a
158 $ hg lognull
160 $ hg lognull
159 -1:000000000000
161 -1:000000000000
160
162
161
163
162 properly recursive
164 properly recursive
163
165
164 $ hg dln
166 $ hg dln
165 changeset: -1:0000000000000000000000000000000000000000
167 changeset: -1:0000000000000000000000000000000000000000
166 parent: -1:0000000000000000000000000000000000000000
168 parent: -1:0000000000000000000000000000000000000000
167 parent: -1:0000000000000000000000000000000000000000
169 parent: -1:0000000000000000000000000000000000000000
168 manifest: -1:0000000000000000000000000000000000000000
170 manifest: -1:0000000000000000000000000000000000000000
169 user:
171 user:
170 date: Thu Jan 01 00:00:00 1970 +0000
172 date: Thu Jan 01 00:00:00 1970 +0000
171 extra: branch=default
173 extra: branch=default
172
174
173
175
174
176
175 path expanding
177 path expanding
176
178
177 $ FOO=`pwd` hg put
179 $ FOO=`pwd` hg put
178 $ cat 0.diff
180 $ cat 0.diff
179 # HG changeset patch
181 # HG changeset patch
180 # User test
182 # User test
181 # Date 0 0
183 # Date 0 0
182 # Node ID e63c23eaa88ae77967edcf4ea194d31167c478b0
184 # Node ID e63c23eaa88ae77967edcf4ea194d31167c478b0
183 # Parent 0000000000000000000000000000000000000000
185 # Parent 0000000000000000000000000000000000000000
184 foo
186 foo
185
187
186 diff -r 000000000000 -r e63c23eaa88a foo
188 diff -r 000000000000 -r e63c23eaa88a foo
187 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
189 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
188 +++ b/foo Thu Jan 01 00:00:00 1970 +0000
190 +++ b/foo Thu Jan 01 00:00:00 1970 +0000
189 @@ -0,0 +1,1 @@
191 @@ -0,0 +1,1 @@
190 +foo
192 +foo
191
193
192
194
193 simple shell aliases
195 simple shell aliases
194
196
195 $ hg blank
197 $ hg blank
196
198
197 $ hg blank foo
199 $ hg blank foo
198
200
199 $ hg self
201 $ hg self
200 self
202 self
201 $ hg echoall
203 $ hg echoall
202
204
203 $ hg echoall foo
205 $ hg echoall foo
204 foo
206 foo
205 $ hg echoall 'test $2' foo
207 $ hg echoall 'test $2' foo
206 test $2 foo
208 test $2 foo
207 $ hg echo1 foo bar baz
209 $ hg echo1 foo bar baz
208 foo
210 foo
209 $ hg echo2 foo bar baz
211 $ hg echo2 foo bar baz
210 bar
212 bar
211 $ hg echo13 foo bar baz test
213 $ hg echo13 foo bar baz test
212 foo baz
214 foo baz
213 $ hg echo2 foo
215 $ hg echo2 foo
214
216
215 $ echo bar > bar
217 $ echo bar > bar
216 $ hg commit -qA -m bar
218 $ hg commit -qA -m bar
217 $ hg count .
219 $ hg count .
218 1
220 1
219 $ hg count 'branch(default)'
221 $ hg count 'branch(default)'
220 2
222 2
221 $ hg mcount -r '"branch(default)"'
223 $ hg mcount -r '"branch(default)"'
222 2
224 2
223
225
224 $ hg tglog
226 $ hg tglog
225 @ 1:7e7f92de180e: 'bar'
227 @ 1:7e7f92de180e: 'bar'
226 |
228 |
227 o 0:e63c23eaa88a: 'foo'
229 o 0:e63c23eaa88a: 'foo'
228
230
229
231
230
232
231 shadowing
233 shadowing
232
234
233 $ hg i
235 $ hg i
234 hg: command 'i' is ambiguous:
236 hg: command 'i' is ambiguous:
235 idalias idaliaslong idaliasshell identify import incoming init
237 idalias idaliaslong idaliasshell identify import incoming init
236 [255]
238 [255]
237 $ hg id
239 $ hg id
238 7e7f92de180e tip
240 7e7f92de180e tip
239 $ hg ida
241 $ hg ida
240 hg: command 'ida' is ambiguous:
242 hg: command 'ida' is ambiguous:
241 idalias idaliaslong idaliasshell
243 idalias idaliaslong idaliasshell
242 [255]
244 [255]
243 $ hg idalias
245 $ hg idalias
244 7e7f92de180e tip
246 7e7f92de180e tip
245 $ hg idaliasl
247 $ hg idaliasl
246 7e7f92de180e tip
248 7e7f92de180e tip
247 $ hg idaliass
249 $ hg idaliass
248 test
250 test
249 $ hg parentsshell
251 $ hg parentsshell
250 hg: command 'parentsshell' is ambiguous:
252 hg: command 'parentsshell' is ambiguous:
251 parentsshell1 parentsshell2
253 parentsshell1 parentsshell2
252 [255]
254 [255]
253 $ hg parentsshell1
255 $ hg parentsshell1
254 one
256 one
255 $ hg parentsshell2
257 $ hg parentsshell2
256 two
258 two
257
259
258
260
259 shell aliases with global options
261 shell aliases with global options
260
262
261 $ hg init sub
263 $ hg init sub
262 $ cd sub
264 $ cd sub
263 $ hg count 'branch(default)'
265 $ hg count 'branch(default)'
264 0
266 0
265 $ hg -v count 'branch(default)'
267 $ hg -v count 'branch(default)'
266 0
268 0
267 $ hg -R .. count 'branch(default)'
269 $ hg -R .. count 'branch(default)'
268 0
270 0
269 $ hg --cwd .. count 'branch(default)'
271 $ hg --cwd .. count 'branch(default)'
270 2
272 2
271 $ hg echoall --cwd ..
273 $ hg echoall --cwd ..
272
274
273
275
274
276
275 repo specific shell aliases
277 repo specific shell aliases
276
278
277 $ cat >> .hg/hgrc <<EOF
279 $ cat >> .hg/hgrc <<EOF
278 > [alias]
280 > [alias]
279 > subalias = !echo sub
281 > subalias = !echo sub
280 > EOF
282 > EOF
281 $ cat >> ../.hg/hgrc <<EOF
283 $ cat >> ../.hg/hgrc <<EOF
282 > [alias]
284 > [alias]
283 > mainalias = !echo main
285 > mainalias = !echo main
284 > EOF
286 > EOF
285
287
286
288
287 shell alias defined in current repo
289 shell alias defined in current repo
288
290
289 $ hg subalias
291 $ hg subalias
290 sub
292 sub
291 $ hg --cwd .. subalias > /dev/null
293 $ hg --cwd .. subalias > /dev/null
292 hg: unknown command 'subalias'
294 hg: unknown command 'subalias'
293 [255]
295 [255]
294 $ hg -R .. subalias > /dev/null
296 $ hg -R .. subalias > /dev/null
295 hg: unknown command 'subalias'
297 hg: unknown command 'subalias'
296 [255]
298 [255]
297
299
298
300
299 shell alias defined in other repo
301 shell alias defined in other repo
300
302
301 $ hg mainalias > /dev/null
303 $ hg mainalias > /dev/null
302 hg: unknown command 'mainalias'
304 hg: unknown command 'mainalias'
303 [255]
305 [255]
304 $ hg -R .. mainalias
306 $ hg -R .. mainalias
305 main
307 main
306 $ hg --cwd .. mainalias
308 $ hg --cwd .. mainalias
307 main
309 main
308
310
309
311
310 shell aliases with escaped $ chars
312 shell aliases with escaped $ chars
311
313
312 $ hg escaped1
314 $ hg escaped1
313 test$test
315 test$test
314 $ hg escaped2
316 $ hg escaped2
315 HGFOO is BAR
317 HGFOO is BAR
316 $ hg escaped3 HGFOO
318 $ hg escaped3 HGFOO
317 HGFOO is BAR
319 HGFOO is BAR
318 $ hg escaped4 test
320 $ hg escaped4 test
319 $0 $@
321 $0 $@
320
322
321
323
322 invalid arguments
324 invalid arguments
323
325
324 $ hg rt foo
326 $ hg rt foo
325 hg rt: invalid arguments
327 hg rt: invalid arguments
326 hg rt
328 hg rt
327
329
328 alias for: hg root
330 alias for: hg root
329
331
330 use "hg help rt" to show the full help text
332 use "hg help rt" to show the full help text
331 [255]
333 [255]
332
334
333 invalid global arguments for normal commands, aliases, and shell aliases
335 invalid global arguments for normal commands, aliases, and shell aliases
334
336
335 $ hg --invalid root
337 $ hg --invalid root
336 hg: option --invalid not recognized
338 hg: option --invalid not recognized
337 Mercurial Distributed SCM
339 Mercurial Distributed SCM
338
340
339 basic commands:
341 basic commands:
340
342
341 add add the specified files on the next commit
343 add add the specified files on the next commit
342 annotate show changeset information by line for each file
344 annotate show changeset information by line for each file
343 clone make a copy of an existing repository
345 clone make a copy of an existing repository
344 commit commit the specified files or all outstanding changes
346 commit commit the specified files or all outstanding changes
345 diff diff repository (or selected files)
347 diff diff repository (or selected files)
346 export dump the header and diffs for one or more changesets
348 export dump the header and diffs for one or more changesets
347 forget forget the specified files on the next commit
349 forget forget the specified files on the next commit
348 init create a new repository in the given directory
350 init create a new repository in the given directory
349 log show revision history of entire repository or files
351 log show revision history of entire repository or files
350 merge merge working directory with another revision
352 merge merge working directory with another revision
351 phase set or show the current phase name
353 phase set or show the current phase name
352 pull pull changes from the specified source
354 pull pull changes from the specified source
353 push push changes to the specified destination
355 push push changes to the specified destination
354 remove remove the specified files on the next commit
356 remove remove the specified files on the next commit
355 serve start stand-alone webserver
357 serve start stand-alone webserver
356 status show changed files in the working directory
358 status show changed files in the working directory
357 summary summarize working directory state
359 summary summarize working directory state
358 update update working directory (or switch revisions)
360 update update working directory (or switch revisions)
359
361
360 use "hg help" for the full list of commands or "hg -v" for details
362 use "hg help" for the full list of commands or "hg -v" for details
361 [255]
363 [255]
362 $ hg --invalid mylog
364 $ hg --invalid mylog
363 hg: option --invalid not recognized
365 hg: option --invalid not recognized
364 Mercurial Distributed SCM
366 Mercurial Distributed SCM
365
367
366 basic commands:
368 basic commands:
367
369
368 add add the specified files on the next commit
370 add add the specified files on the next commit
369 annotate show changeset information by line for each file
371 annotate show changeset information by line for each file
370 clone make a copy of an existing repository
372 clone make a copy of an existing repository
371 commit commit the specified files or all outstanding changes
373 commit commit the specified files or all outstanding changes
372 diff diff repository (or selected files)
374 diff diff repository (or selected files)
373 export dump the header and diffs for one or more changesets
375 export dump the header and diffs for one or more changesets
374 forget forget the specified files on the next commit
376 forget forget the specified files on the next commit
375 init create a new repository in the given directory
377 init create a new repository in the given directory
376 log show revision history of entire repository or files
378 log show revision history of entire repository or files
377 merge merge working directory with another revision
379 merge merge working directory with another revision
378 phase set or show the current phase name
380 phase set or show the current phase name
379 pull pull changes from the specified source
381 pull pull changes from the specified source
380 push push changes to the specified destination
382 push push changes to the specified destination
381 remove remove the specified files on the next commit
383 remove remove the specified files on the next commit
382 serve start stand-alone webserver
384 serve start stand-alone webserver
383 status show changed files in the working directory
385 status show changed files in the working directory
384 summary summarize working directory state
386 summary summarize working directory state
385 update update working directory (or switch revisions)
387 update update working directory (or switch revisions)
386
388
387 use "hg help" for the full list of commands or "hg -v" for details
389 use "hg help" for the full list of commands or "hg -v" for details
388 [255]
390 [255]
389 $ hg --invalid blank
391 $ hg --invalid blank
390 hg: option --invalid not recognized
392 hg: option --invalid not recognized
391 Mercurial Distributed SCM
393 Mercurial Distributed SCM
392
394
393 basic commands:
395 basic commands:
394
396
395 add add the specified files on the next commit
397 add add the specified files on the next commit
396 annotate show changeset information by line for each file
398 annotate show changeset information by line for each file
397 clone make a copy of an existing repository
399 clone make a copy of an existing repository
398 commit commit the specified files or all outstanding changes
400 commit commit the specified files or all outstanding changes
399 diff diff repository (or selected files)
401 diff diff repository (or selected files)
400 export dump the header and diffs for one or more changesets
402 export dump the header and diffs for one or more changesets
401 forget forget the specified files on the next commit
403 forget forget the specified files on the next commit
402 init create a new repository in the given directory
404 init create a new repository in the given directory
403 log show revision history of entire repository or files
405 log show revision history of entire repository or files
404 merge merge working directory with another revision
406 merge merge working directory with another revision
405 phase set or show the current phase name
407 phase set or show the current phase name
406 pull pull changes from the specified source
408 pull pull changes from the specified source
407 push push changes to the specified destination
409 push push changes to the specified destination
408 remove remove the specified files on the next commit
410 remove remove the specified files on the next commit
409 serve start stand-alone webserver
411 serve start stand-alone webserver
410 status show changed files in the working directory
412 status show changed files in the working directory
411 summary summarize working directory state
413 summary summarize working directory state
412 update update working directory (or switch revisions)
414 update update working directory (or switch revisions)
413
415
414 use "hg help" for the full list of commands or "hg -v" for details
416 use "hg help" for the full list of commands or "hg -v" for details
415 [255]
417 [255]
416
418
417 This should show id:
419 This should show id:
418
420
419 $ hg --config alias.log='id' log
421 $ hg --config alias.log='id' log
420 000000000000 tip
422 000000000000 tip
421
423
422 This shouldn't:
424 This shouldn't:
423
425
424 $ hg --config alias.log='id' history
426 $ hg --config alias.log='id' history
425
427
426 $ cd ../..
428 $ cd ../..
@@ -1,600 +1,603 b''
1 Setting up test
1 Setting up test
2
2
3 $ hg init test
3 $ hg init test
4 $ cd test
4 $ cd test
5 $ echo 0 > afile
5 $ echo 0 > afile
6 $ hg add afile
6 $ hg add afile
7 $ hg commit -m "0.0"
7 $ hg commit -m "0.0"
8 $ echo 1 >> afile
8 $ echo 1 >> afile
9 $ hg commit -m "0.1"
9 $ hg commit -m "0.1"
10 $ echo 2 >> afile
10 $ echo 2 >> afile
11 $ hg commit -m "0.2"
11 $ hg commit -m "0.2"
12 $ echo 3 >> afile
12 $ echo 3 >> afile
13 $ hg commit -m "0.3"
13 $ hg commit -m "0.3"
14 $ hg update -C 0
14 $ hg update -C 0
15 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
15 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
16 $ echo 1 >> afile
16 $ echo 1 >> afile
17 $ hg commit -m "1.1"
17 $ hg commit -m "1.1"
18 created new head
18 created new head
19 $ echo 2 >> afile
19 $ echo 2 >> afile
20 $ hg commit -m "1.2"
20 $ hg commit -m "1.2"
21 $ echo "a line" > fred
21 $ echo "a line" > fred
22 $ echo 3 >> afile
22 $ echo 3 >> afile
23 $ hg add fred
23 $ hg add fred
24 $ hg commit -m "1.3"
24 $ hg commit -m "1.3"
25 $ hg mv afile adifferentfile
25 $ hg mv afile adifferentfile
26 $ hg commit -m "1.3m"
26 $ hg commit -m "1.3m"
27 $ hg update -C 3
27 $ hg update -C 3
28 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
28 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
29 $ hg mv afile anotherfile
29 $ hg mv afile anotherfile
30 $ hg commit -m "0.3m"
30 $ hg commit -m "0.3m"
31 $ hg verify
31 $ hg verify
32 checking changesets
32 checking changesets
33 checking manifests
33 checking manifests
34 crosschecking files in changesets and manifests
34 crosschecking files in changesets and manifests
35 checking files
35 checking files
36 4 files, 9 changesets, 7 total revisions
36 4 files, 9 changesets, 7 total revisions
37 $ cd ..
37 $ cd ..
38 $ hg init empty
38 $ hg init empty
39
39
40 Bundle and phase
40 Bundle and phase
41
41
42 $ hg -R test phase --force --secret 0
42 $ hg -R test phase --force --secret 0
43 $ hg -R test bundle phase.hg empty
43 $ hg -R test bundle phase.hg empty
44 searching for changes
44 searching for changes
45 no changes found (ignored 9 secret changesets)
45 no changes found (ignored 9 secret changesets)
46 [1]
46 [1]
47 $ hg -R test phase --draft -r 'head()'
47 $ hg -R test phase --draft -r 'head()'
48
48
49 Bundle --all
49 Bundle --all
50
50
51 $ hg -R test bundle --all all.hg
51 $ hg -R test bundle --all all.hg
52 9 changesets found
52 9 changesets found
53
53
54 Bundle test to full.hg
54 Bundle test to full.hg
55
55
56 $ hg -R test bundle full.hg empty
56 $ hg -R test bundle full.hg empty
57 searching for changes
57 searching for changes
58 9 changesets found
58 9 changesets found
59
59
60 Unbundle full.hg in test
60 Unbundle full.hg in test
61
61
62 $ hg -R test unbundle full.hg
62 $ hg -R test unbundle full.hg
63 adding changesets
63 adding changesets
64 adding manifests
64 adding manifests
65 adding file changes
65 adding file changes
66 added 0 changesets with 0 changes to 4 files
66 added 0 changesets with 0 changes to 4 files
67 (run 'hg update' to get a working copy)
67 (run 'hg update' to get a working copy)
68
68
69 Verify empty
69 Verify empty
70
70
71 $ hg -R empty heads
71 $ hg -R empty heads
72 [1]
72 [1]
73 $ hg -R empty verify
73 $ hg -R empty verify
74 checking changesets
74 checking changesets
75 checking manifests
75 checking manifests
76 crosschecking files in changesets and manifests
76 crosschecking files in changesets and manifests
77 checking files
77 checking files
78 0 files, 0 changesets, 0 total revisions
78 0 files, 0 changesets, 0 total revisions
79
79
80 Pull full.hg into test (using --cwd)
80 Pull full.hg into test (using --cwd)
81
81
82 $ hg --cwd test pull ../full.hg
82 $ hg --cwd test pull ../full.hg
83 pulling from ../full.hg
83 pulling from ../full.hg
84 searching for changes
84 searching for changes
85 no changes found
85 no changes found
86
86
87 Pull full.hg into empty (using --cwd)
87 Pull full.hg into empty (using --cwd)
88
88
89 $ hg --cwd empty pull ../full.hg
89 $ hg --cwd empty pull ../full.hg
90 pulling from ../full.hg
90 pulling from ../full.hg
91 requesting all changes
91 requesting all changes
92 adding changesets
92 adding changesets
93 adding manifests
93 adding manifests
94 adding file changes
94 adding file changes
95 added 9 changesets with 7 changes to 4 files (+1 heads)
95 added 9 changesets with 7 changes to 4 files (+1 heads)
96 (run 'hg heads' to see heads, 'hg merge' to merge)
96 (run 'hg heads' to see heads, 'hg merge' to merge)
97
97
98 Rollback empty
98 Rollback empty
99
99
100 $ hg -R empty rollback
100 $ hg -R empty rollback
101 repository tip rolled back to revision -1 (undo pull)
101 repository tip rolled back to revision -1 (undo pull)
102
102
103 Pull full.hg into empty again (using --cwd)
103 Pull full.hg into empty again (using --cwd)
104
104
105 $ hg --cwd empty pull ../full.hg
105 $ hg --cwd empty pull ../full.hg
106 pulling from ../full.hg
106 pulling from ../full.hg
107 requesting all changes
107 requesting all changes
108 adding changesets
108 adding changesets
109 adding manifests
109 adding manifests
110 adding file changes
110 adding file changes
111 added 9 changesets with 7 changes to 4 files (+1 heads)
111 added 9 changesets with 7 changes to 4 files (+1 heads)
112 (run 'hg heads' to see heads, 'hg merge' to merge)
112 (run 'hg heads' to see heads, 'hg merge' to merge)
113
113
114 Pull full.hg into test (using -R)
114 Pull full.hg into test (using -R)
115
115
116 $ hg -R test pull full.hg
116 $ hg -R test pull full.hg
117 pulling from full.hg
117 pulling from full.hg
118 searching for changes
118 searching for changes
119 no changes found
119 no changes found
120
120
121 Pull full.hg into empty (using -R)
121 Pull full.hg into empty (using -R)
122
122
123 $ hg -R empty pull full.hg
123 $ hg -R empty pull full.hg
124 pulling from full.hg
124 pulling from full.hg
125 searching for changes
125 searching for changes
126 no changes found
126 no changes found
127
127
128 Rollback empty
128 Rollback empty
129
129
130 $ hg -R empty rollback
130 $ hg -R empty rollback
131 repository tip rolled back to revision -1 (undo pull)
131 repository tip rolled back to revision -1 (undo pull)
132
132
133 Pull full.hg into empty again (using -R)
133 Pull full.hg into empty again (using -R)
134
134
135 $ hg -R empty pull full.hg
135 $ hg -R empty pull full.hg
136 pulling from full.hg
136 pulling from full.hg
137 requesting all changes
137 requesting all changes
138 adding changesets
138 adding changesets
139 adding manifests
139 adding manifests
140 adding file changes
140 adding file changes
141 added 9 changesets with 7 changes to 4 files (+1 heads)
141 added 9 changesets with 7 changes to 4 files (+1 heads)
142 (run 'hg heads' to see heads, 'hg merge' to merge)
142 (run 'hg heads' to see heads, 'hg merge' to merge)
143
143
144 Log -R full.hg in fresh empty
144 Log -R full.hg in fresh empty
145
145
146 $ rm -r empty
146 $ rm -r empty
147 $ hg init empty
147 $ hg init empty
148 $ cd empty
148 $ cd empty
149 $ hg -R bundle://../full.hg log
149 $ hg -R bundle://../full.hg log
150 changeset: 8:aa35859c02ea
150 changeset: 8:aa35859c02ea
151 tag: tip
151 tag: tip
152 parent: 3:eebf5a27f8ca
152 parent: 3:eebf5a27f8ca
153 user: test
153 user: test
154 date: Thu Jan 01 00:00:00 1970 +0000
154 date: Thu Jan 01 00:00:00 1970 +0000
155 summary: 0.3m
155 summary: 0.3m
156
156
157 changeset: 7:a6a34bfa0076
157 changeset: 7:a6a34bfa0076
158 user: test
158 user: test
159 date: Thu Jan 01 00:00:00 1970 +0000
159 date: Thu Jan 01 00:00:00 1970 +0000
160 summary: 1.3m
160 summary: 1.3m
161
161
162 changeset: 6:7373c1169842
162 changeset: 6:7373c1169842
163 user: test
163 user: test
164 date: Thu Jan 01 00:00:00 1970 +0000
164 date: Thu Jan 01 00:00:00 1970 +0000
165 summary: 1.3
165 summary: 1.3
166
166
167 changeset: 5:1bb50a9436a7
167 changeset: 5:1bb50a9436a7
168 user: test
168 user: test
169 date: Thu Jan 01 00:00:00 1970 +0000
169 date: Thu Jan 01 00:00:00 1970 +0000
170 summary: 1.2
170 summary: 1.2
171
171
172 changeset: 4:095197eb4973
172 changeset: 4:095197eb4973
173 parent: 0:f9ee2f85a263
173 parent: 0:f9ee2f85a263
174 user: test
174 user: test
175 date: Thu Jan 01 00:00:00 1970 +0000
175 date: Thu Jan 01 00:00:00 1970 +0000
176 summary: 1.1
176 summary: 1.1
177
177
178 changeset: 3:eebf5a27f8ca
178 changeset: 3:eebf5a27f8ca
179 user: test
179 user: test
180 date: Thu Jan 01 00:00:00 1970 +0000
180 date: Thu Jan 01 00:00:00 1970 +0000
181 summary: 0.3
181 summary: 0.3
182
182
183 changeset: 2:e38ba6f5b7e0
183 changeset: 2:e38ba6f5b7e0
184 user: test
184 user: test
185 date: Thu Jan 01 00:00:00 1970 +0000
185 date: Thu Jan 01 00:00:00 1970 +0000
186 summary: 0.2
186 summary: 0.2
187
187
188 changeset: 1:34c2bf6b0626
188 changeset: 1:34c2bf6b0626
189 user: test
189 user: test
190 date: Thu Jan 01 00:00:00 1970 +0000
190 date: Thu Jan 01 00:00:00 1970 +0000
191 summary: 0.1
191 summary: 0.1
192
192
193 changeset: 0:f9ee2f85a263
193 changeset: 0:f9ee2f85a263
194 user: test
194 user: test
195 date: Thu Jan 01 00:00:00 1970 +0000
195 date: Thu Jan 01 00:00:00 1970 +0000
196 summary: 0.0
196 summary: 0.0
197
197
198 Make sure bundlerepo doesn't leak tempfiles (issue2491)
198 Make sure bundlerepo doesn't leak tempfiles (issue2491)
199
199
200 $ ls .hg
200 $ ls .hg
201 00changelog.i
201 00changelog.i
202 cache
202 cache
203 requires
203 requires
204 store
204 store
205
205
206 Pull ../full.hg into empty (with hook)
206 Pull ../full.hg into empty (with hook)
207
207
208 $ echo "[hooks]" >> .hg/hgrc
208 $ echo "[hooks]" >> .hg/hgrc
209 $ echo "changegroup = python \"$TESTDIR\"/printenv.py changegroup" >> .hg/hgrc
209 $ echo "changegroup = python \"$TESTDIR\"/printenv.py changegroup" >> .hg/hgrc
210
210
211 doesn't work (yet ?)
211 doesn't work (yet ?)
212
212
213 hg -R bundle://../full.hg verify
213 hg -R bundle://../full.hg verify
214
214
215 $ hg pull bundle://../full.hg
215 $ hg pull bundle://../full.hg
216 pulling from bundle:../full.hg
216 pulling from bundle:../full.hg
217 requesting all changes
217 requesting all changes
218 adding changesets
218 adding changesets
219 adding manifests
219 adding manifests
220 adding file changes
220 adding file changes
221 added 9 changesets with 7 changes to 4 files (+1 heads)
221 added 9 changesets with 7 changes to 4 files (+1 heads)
222 changegroup hook: HG_NODE=f9ee2f85a263049e9ae6d37a0e67e96194ffb735 HG_SOURCE=pull HG_URL=bundle:../full.hg
222 changegroup hook: HG_NODE=f9ee2f85a263049e9ae6d37a0e67e96194ffb735 HG_SOURCE=pull HG_URL=bundle:../full.hg
223 (run 'hg heads' to see heads, 'hg merge' to merge)
223 (run 'hg heads' to see heads, 'hg merge' to merge)
224
224
225 Rollback empty
225 Rollback empty
226
226
227 $ hg rollback
227 $ hg rollback
228 repository tip rolled back to revision -1 (undo pull)
228 repository tip rolled back to revision -1 (undo pull)
229 $ cd ..
229 $ cd ..
230
230
231 Log -R bundle:empty+full.hg
231 Log -R bundle:empty+full.hg
232
232
233 $ hg -R bundle:empty+full.hg log --template="{rev} "; echo ""
233 $ hg -R bundle:empty+full.hg log --template="{rev} "; echo ""
234 8 7 6 5 4 3 2 1 0
234 8 7 6 5 4 3 2 1 0
235
235
236 Pull full.hg into empty again (using -R; with hook)
236 Pull full.hg into empty again (using -R; with hook)
237
237
238 $ hg -R empty pull full.hg
238 $ hg -R empty pull full.hg
239 pulling from full.hg
239 pulling from full.hg
240 requesting all changes
240 requesting all changes
241 adding changesets
241 adding changesets
242 adding manifests
242 adding manifests
243 adding file changes
243 adding file changes
244 added 9 changesets with 7 changes to 4 files (+1 heads)
244 added 9 changesets with 7 changes to 4 files (+1 heads)
245 changegroup hook: HG_NODE=f9ee2f85a263049e9ae6d37a0e67e96194ffb735 HG_SOURCE=pull HG_URL=bundle:empty+full.hg
245 changegroup hook: HG_NODE=f9ee2f85a263049e9ae6d37a0e67e96194ffb735 HG_SOURCE=pull HG_URL=bundle:empty+full.hg
246 (run 'hg heads' to see heads, 'hg merge' to merge)
246 (run 'hg heads' to see heads, 'hg merge' to merge)
247
247
248 Create partial clones
248 Create partial clones
249
249
250 $ rm -r empty
250 $ rm -r empty
251 $ hg init empty
251 $ hg init empty
252 $ hg clone -r 3 test partial
252 $ hg clone -r 3 test partial
253 adding changesets
253 adding changesets
254 adding manifests
254 adding manifests
255 adding file changes
255 adding file changes
256 added 4 changesets with 4 changes to 1 files
256 added 4 changesets with 4 changes to 1 files
257 updating to branch default
257 updating to branch default
258 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
258 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
259 $ hg clone partial partial2
259 $ hg clone partial partial2
260 updating to branch default
260 updating to branch default
261 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
261 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
262 $ cd partial
262 $ cd partial
263
263
264 Log -R full.hg in partial
264 Log -R full.hg in partial
265
265
266 $ hg -R bundle://../full.hg log
266 $ hg -R bundle://../full.hg log
267 changeset: 8:aa35859c02ea
267 changeset: 8:aa35859c02ea
268 tag: tip
268 tag: tip
269 parent: 3:eebf5a27f8ca
269 parent: 3:eebf5a27f8ca
270 user: test
270 user: test
271 date: Thu Jan 01 00:00:00 1970 +0000
271 date: Thu Jan 01 00:00:00 1970 +0000
272 summary: 0.3m
272 summary: 0.3m
273
273
274 changeset: 7:a6a34bfa0076
274 changeset: 7:a6a34bfa0076
275 user: test
275 user: test
276 date: Thu Jan 01 00:00:00 1970 +0000
276 date: Thu Jan 01 00:00:00 1970 +0000
277 summary: 1.3m
277 summary: 1.3m
278
278
279 changeset: 6:7373c1169842
279 changeset: 6:7373c1169842
280 user: test
280 user: test
281 date: Thu Jan 01 00:00:00 1970 +0000
281 date: Thu Jan 01 00:00:00 1970 +0000
282 summary: 1.3
282 summary: 1.3
283
283
284 changeset: 5:1bb50a9436a7
284 changeset: 5:1bb50a9436a7
285 user: test
285 user: test
286 date: Thu Jan 01 00:00:00 1970 +0000
286 date: Thu Jan 01 00:00:00 1970 +0000
287 summary: 1.2
287 summary: 1.2
288
288
289 changeset: 4:095197eb4973
289 changeset: 4:095197eb4973
290 parent: 0:f9ee2f85a263
290 parent: 0:f9ee2f85a263
291 user: test
291 user: test
292 date: Thu Jan 01 00:00:00 1970 +0000
292 date: Thu Jan 01 00:00:00 1970 +0000
293 summary: 1.1
293 summary: 1.1
294
294
295 changeset: 3:eebf5a27f8ca
295 changeset: 3:eebf5a27f8ca
296 user: test
296 user: test
297 date: Thu Jan 01 00:00:00 1970 +0000
297 date: Thu Jan 01 00:00:00 1970 +0000
298 summary: 0.3
298 summary: 0.3
299
299
300 changeset: 2:e38ba6f5b7e0
300 changeset: 2:e38ba6f5b7e0
301 user: test
301 user: test
302 date: Thu Jan 01 00:00:00 1970 +0000
302 date: Thu Jan 01 00:00:00 1970 +0000
303 summary: 0.2
303 summary: 0.2
304
304
305 changeset: 1:34c2bf6b0626
305 changeset: 1:34c2bf6b0626
306 user: test
306 user: test
307 date: Thu Jan 01 00:00:00 1970 +0000
307 date: Thu Jan 01 00:00:00 1970 +0000
308 summary: 0.1
308 summary: 0.1
309
309
310 changeset: 0:f9ee2f85a263
310 changeset: 0:f9ee2f85a263
311 user: test
311 user: test
312 date: Thu Jan 01 00:00:00 1970 +0000
312 date: Thu Jan 01 00:00:00 1970 +0000
313 summary: 0.0
313 summary: 0.0
314
314
315
315
316 Incoming full.hg in partial
316 Incoming full.hg in partial
317
317
318 $ hg incoming bundle://../full.hg
318 $ hg incoming bundle://../full.hg
319 comparing with bundle:../full.hg
319 comparing with bundle:../full.hg
320 searching for changes
320 searching for changes
321 changeset: 4:095197eb4973
321 changeset: 4:095197eb4973
322 parent: 0:f9ee2f85a263
322 parent: 0:f9ee2f85a263
323 user: test
323 user: test
324 date: Thu Jan 01 00:00:00 1970 +0000
324 date: Thu Jan 01 00:00:00 1970 +0000
325 summary: 1.1
325 summary: 1.1
326
326
327 changeset: 5:1bb50a9436a7
327 changeset: 5:1bb50a9436a7
328 user: test
328 user: test
329 date: Thu Jan 01 00:00:00 1970 +0000
329 date: Thu Jan 01 00:00:00 1970 +0000
330 summary: 1.2
330 summary: 1.2
331
331
332 changeset: 6:7373c1169842
332 changeset: 6:7373c1169842
333 user: test
333 user: test
334 date: Thu Jan 01 00:00:00 1970 +0000
334 date: Thu Jan 01 00:00:00 1970 +0000
335 summary: 1.3
335 summary: 1.3
336
336
337 changeset: 7:a6a34bfa0076
337 changeset: 7:a6a34bfa0076
338 user: test
338 user: test
339 date: Thu Jan 01 00:00:00 1970 +0000
339 date: Thu Jan 01 00:00:00 1970 +0000
340 summary: 1.3m
340 summary: 1.3m
341
341
342 changeset: 8:aa35859c02ea
342 changeset: 8:aa35859c02ea
343 tag: tip
343 tag: tip
344 parent: 3:eebf5a27f8ca
344 parent: 3:eebf5a27f8ca
345 user: test
345 user: test
346 date: Thu Jan 01 00:00:00 1970 +0000
346 date: Thu Jan 01 00:00:00 1970 +0000
347 summary: 0.3m
347 summary: 0.3m
348
348
349
349
350 Outgoing -R full.hg vs partial2 in partial
350 Outgoing -R full.hg vs partial2 in partial
351
351
352 $ hg -R bundle://../full.hg outgoing ../partial2
352 $ hg -R bundle://../full.hg outgoing ../partial2
353 comparing with ../partial2
353 comparing with ../partial2
354 searching for changes
354 searching for changes
355 changeset: 4:095197eb4973
355 changeset: 4:095197eb4973
356 parent: 0:f9ee2f85a263
356 parent: 0:f9ee2f85a263
357 user: test
357 user: test
358 date: Thu Jan 01 00:00:00 1970 +0000
358 date: Thu Jan 01 00:00:00 1970 +0000
359 summary: 1.1
359 summary: 1.1
360
360
361 changeset: 5:1bb50a9436a7
361 changeset: 5:1bb50a9436a7
362 user: test
362 user: test
363 date: Thu Jan 01 00:00:00 1970 +0000
363 date: Thu Jan 01 00:00:00 1970 +0000
364 summary: 1.2
364 summary: 1.2
365
365
366 changeset: 6:7373c1169842
366 changeset: 6:7373c1169842
367 user: test
367 user: test
368 date: Thu Jan 01 00:00:00 1970 +0000
368 date: Thu Jan 01 00:00:00 1970 +0000
369 summary: 1.3
369 summary: 1.3
370
370
371 changeset: 7:a6a34bfa0076
371 changeset: 7:a6a34bfa0076
372 user: test
372 user: test
373 date: Thu Jan 01 00:00:00 1970 +0000
373 date: Thu Jan 01 00:00:00 1970 +0000
374 summary: 1.3m
374 summary: 1.3m
375
375
376 changeset: 8:aa35859c02ea
376 changeset: 8:aa35859c02ea
377 tag: tip
377 tag: tip
378 parent: 3:eebf5a27f8ca
378 parent: 3:eebf5a27f8ca
379 user: test
379 user: test
380 date: Thu Jan 01 00:00:00 1970 +0000
380 date: Thu Jan 01 00:00:00 1970 +0000
381 summary: 0.3m
381 summary: 0.3m
382
382
383
383
384 Outgoing -R does-not-exist.hg vs partial2 in partial
384 Outgoing -R does-not-exist.hg vs partial2 in partial
385
385
386 $ hg -R bundle://../does-not-exist.hg outgoing ../partial2
386 $ hg -R bundle://../does-not-exist.hg outgoing ../partial2
387 abort: *../does-not-exist.hg* (glob)
387 abort: *../does-not-exist.hg* (glob)
388 [255]
388 [255]
389 $ cd ..
389 $ cd ..
390
390
391 hide outer repo
392 $ hg init
393
391 Direct clone from bundle (all-history)
394 Direct clone from bundle (all-history)
392
395
393 $ hg clone full.hg full-clone
396 $ hg clone full.hg full-clone
394 requesting all changes
397 requesting all changes
395 adding changesets
398 adding changesets
396 adding manifests
399 adding manifests
397 adding file changes
400 adding file changes
398 added 9 changesets with 7 changes to 4 files (+1 heads)
401 added 9 changesets with 7 changes to 4 files (+1 heads)
399 updating to branch default
402 updating to branch default
400 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
403 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
401 $ hg -R full-clone heads
404 $ hg -R full-clone heads
402 changeset: 8:aa35859c02ea
405 changeset: 8:aa35859c02ea
403 tag: tip
406 tag: tip
404 parent: 3:eebf5a27f8ca
407 parent: 3:eebf5a27f8ca
405 user: test
408 user: test
406 date: Thu Jan 01 00:00:00 1970 +0000
409 date: Thu Jan 01 00:00:00 1970 +0000
407 summary: 0.3m
410 summary: 0.3m
408
411
409 changeset: 7:a6a34bfa0076
412 changeset: 7:a6a34bfa0076
410 user: test
413 user: test
411 date: Thu Jan 01 00:00:00 1970 +0000
414 date: Thu Jan 01 00:00:00 1970 +0000
412 summary: 1.3m
415 summary: 1.3m
413
416
414 $ rm -r full-clone
417 $ rm -r full-clone
415
418
416 When cloning from a non-copiable repository into '', do not
419 When cloning from a non-copiable repository into '', do not
417 recurse infinitely (issue 2528)
420 recurse infinitely (issue 2528)
418
421
419 $ hg clone full.hg ''
422 $ hg clone full.hg ''
420 abort: * (glob)
423 abort: * (glob)
421 [255]
424 [255]
422
425
423 test for http://mercurial.selenic.com/bts/issue216
426 test for http://mercurial.selenic.com/bts/issue216
424
427
425 Unbundle incremental bundles into fresh empty in one go
428 Unbundle incremental bundles into fresh empty in one go
426
429
427 $ rm -r empty
430 $ rm -r empty
428 $ hg init empty
431 $ hg init empty
429 $ hg -R test bundle --base null -r 0 ../0.hg
432 $ hg -R test bundle --base null -r 0 ../0.hg
430 1 changesets found
433 1 changesets found
431 $ hg -R test bundle --base 0 -r 1 ../1.hg
434 $ hg -R test bundle --base 0 -r 1 ../1.hg
432 1 changesets found
435 1 changesets found
433 $ hg -R empty unbundle -u ../0.hg ../1.hg
436 $ hg -R empty unbundle -u ../0.hg ../1.hg
434 adding changesets
437 adding changesets
435 adding manifests
438 adding manifests
436 adding file changes
439 adding file changes
437 added 1 changesets with 1 changes to 1 files
440 added 1 changesets with 1 changes to 1 files
438 adding changesets
441 adding changesets
439 adding manifests
442 adding manifests
440 adding file changes
443 adding file changes
441 added 1 changesets with 1 changes to 1 files
444 added 1 changesets with 1 changes to 1 files
442 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
445 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
443
446
444 test for 540d1059c802
447 test for 540d1059c802
445
448
446 test for 540d1059c802
449 test for 540d1059c802
447
450
448 $ hg init orig
451 $ hg init orig
449 $ cd orig
452 $ cd orig
450 $ echo foo > foo
453 $ echo foo > foo
451 $ hg add foo
454 $ hg add foo
452 $ hg ci -m 'add foo'
455 $ hg ci -m 'add foo'
453
456
454 $ hg clone . ../copy
457 $ hg clone . ../copy
455 updating to branch default
458 updating to branch default
456 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
459 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
457 $ hg tag foo
460 $ hg tag foo
458
461
459 $ cd ../copy
462 $ cd ../copy
460 $ echo >> foo
463 $ echo >> foo
461 $ hg ci -m 'change foo'
464 $ hg ci -m 'change foo'
462 $ hg bundle ../bundle.hg ../orig
465 $ hg bundle ../bundle.hg ../orig
463 searching for changes
466 searching for changes
464 1 changesets found
467 1 changesets found
465
468
466 $ cd ../orig
469 $ cd ../orig
467 $ hg incoming ../bundle.hg
470 $ hg incoming ../bundle.hg
468 comparing with ../bundle.hg
471 comparing with ../bundle.hg
469 searching for changes
472 searching for changes
470 changeset: 2:ed1b79f46b9a
473 changeset: 2:ed1b79f46b9a
471 tag: tip
474 tag: tip
472 parent: 0:bbd179dfa0a7
475 parent: 0:bbd179dfa0a7
473 user: test
476 user: test
474 date: Thu Jan 01 00:00:00 1970 +0000
477 date: Thu Jan 01 00:00:00 1970 +0000
475 summary: change foo
478 summary: change foo
476
479
477 $ cd ..
480 $ cd ..
478
481
479 test bundle with # in the filename (issue2154):
482 test bundle with # in the filename (issue2154):
480
483
481 $ cp bundle.hg 'test#bundle.hg'
484 $ cp bundle.hg 'test#bundle.hg'
482 $ cd orig
485 $ cd orig
483 $ hg incoming '../test#bundle.hg'
486 $ hg incoming '../test#bundle.hg'
484 comparing with ../test
487 comparing with ../test
485 abort: unknown revision 'bundle.hg'!
488 abort: unknown revision 'bundle.hg'!
486 [255]
489 [255]
487
490
488 note that percent encoding is not handled:
491 note that percent encoding is not handled:
489
492
490 $ hg incoming ../test%23bundle.hg
493 $ hg incoming ../test%23bundle.hg
491 abort: repository ../test%23bundle.hg not found!
494 abort: repository ../test%23bundle.hg not found!
492 [255]
495 [255]
493 $ cd ..
496 $ cd ..
494
497
495 test for http://mercurial.selenic.com/bts/issue1144
498 test for http://mercurial.selenic.com/bts/issue1144
496
499
497 test that verify bundle does not traceback
500 test that verify bundle does not traceback
498
501
499 partial history bundle, fails w/ unkown parent
502 partial history bundle, fails w/ unkown parent
500
503
501 $ hg -R bundle.hg verify
504 $ hg -R bundle.hg verify
502 abort: 00changelog.i@bbd179dfa0a7: unknown parent!
505 abort: 00changelog.i@bbd179dfa0a7: unknown parent!
503 [255]
506 [255]
504
507
505 full history bundle, refuses to verify non-local repo
508 full history bundle, refuses to verify non-local repo
506
509
507 $ hg -R all.hg verify
510 $ hg -R all.hg verify
508 abort: cannot verify bundle or remote repos
511 abort: cannot verify bundle or remote repos
509 [255]
512 [255]
510
513
511 but, regular verify must continue to work
514 but, regular verify must continue to work
512
515
513 $ hg -R orig verify
516 $ hg -R orig verify
514 checking changesets
517 checking changesets
515 checking manifests
518 checking manifests
516 crosschecking files in changesets and manifests
519 crosschecking files in changesets and manifests
517 checking files
520 checking files
518 2 files, 2 changesets, 2 total revisions
521 2 files, 2 changesets, 2 total revisions
519
522
520 diff against bundle
523 diff against bundle
521
524
522 $ hg init b
525 $ hg init b
523 $ cd b
526 $ cd b
524 $ hg -R ../all.hg diff -r tip
527 $ hg -R ../all.hg diff -r tip
525 diff -r aa35859c02ea anotherfile
528 diff -r aa35859c02ea anotherfile
526 --- a/anotherfile Thu Jan 01 00:00:00 1970 +0000
529 --- a/anotherfile Thu Jan 01 00:00:00 1970 +0000
527 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
530 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
528 @@ -1,4 +0,0 @@
531 @@ -1,4 +0,0 @@
529 -0
532 -0
530 -1
533 -1
531 -2
534 -2
532 -3
535 -3
533 $ cd ..
536 $ cd ..
534
537
535 bundle single branch
538 bundle single branch
536
539
537 $ hg init branchy
540 $ hg init branchy
538 $ cd branchy
541 $ cd branchy
539 $ echo a >a
542 $ echo a >a
540 $ echo x >x
543 $ echo x >x
541 $ hg ci -Ama
544 $ hg ci -Ama
542 adding a
545 adding a
543 adding x
546 adding x
544 $ echo c >c
547 $ echo c >c
545 $ echo xx >x
548 $ echo xx >x
546 $ hg ci -Amc
549 $ hg ci -Amc
547 adding c
550 adding c
548 $ echo c1 >c1
551 $ echo c1 >c1
549 $ hg ci -Amc1
552 $ hg ci -Amc1
550 adding c1
553 adding c1
551 $ hg up 0
554 $ hg up 0
552 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
555 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
553 $ echo b >b
556 $ echo b >b
554 $ hg ci -Amb
557 $ hg ci -Amb
555 adding b
558 adding b
556 created new head
559 created new head
557 $ echo b1 >b1
560 $ echo b1 >b1
558 $ echo xx >x
561 $ echo xx >x
559 $ hg ci -Amb1
562 $ hg ci -Amb1
560 adding b1
563 adding b1
561 $ hg clone -q -r2 . part
564 $ hg clone -q -r2 . part
562
565
563 == bundling via incoming
566 == bundling via incoming
564
567
565 $ hg in -R part --bundle incoming.hg --template "{node}\n" .
568 $ hg in -R part --bundle incoming.hg --template "{node}\n" .
566 comparing with .
569 comparing with .
567 searching for changes
570 searching for changes
568 1a38c1b849e8b70c756d2d80b0b9a3ac0b7ea11a
571 1a38c1b849e8b70c756d2d80b0b9a3ac0b7ea11a
569 057f4db07f61970e1c11e83be79e9d08adc4dc31
572 057f4db07f61970e1c11e83be79e9d08adc4dc31
570
573
571 == bundling
574 == bundling
572
575
573 $ hg bundle bundle.hg part --debug
576 $ hg bundle bundle.hg part --debug
574 query 1; heads
577 query 1; heads
575 searching for changes
578 searching for changes
576 all remote heads known locally
579 all remote heads known locally
577 2 changesets found
580 2 changesets found
578 list of changesets:
581 list of changesets:
579 1a38c1b849e8b70c756d2d80b0b9a3ac0b7ea11a
582 1a38c1b849e8b70c756d2d80b0b9a3ac0b7ea11a
580 057f4db07f61970e1c11e83be79e9d08adc4dc31
583 057f4db07f61970e1c11e83be79e9d08adc4dc31
581 bundling: 1/2 changesets (50.00%)
584 bundling: 1/2 changesets (50.00%)
582 bundling: 2/2 changesets (100.00%)
585 bundling: 2/2 changesets (100.00%)
583 bundling: 1/2 manifests (50.00%)
586 bundling: 1/2 manifests (50.00%)
584 bundling: 2/2 manifests (100.00%)
587 bundling: 2/2 manifests (100.00%)
585 bundling: b 1/3 files (33.33%)
588 bundling: b 1/3 files (33.33%)
586 bundling: b1 2/3 files (66.67%)
589 bundling: b1 2/3 files (66.67%)
587 bundling: x 3/3 files (100.00%)
590 bundling: x 3/3 files (100.00%)
588
591
589 == Test for issue3441
592 == Test for issue3441
590
593
591 $ hg clone -q -r0 . part2
594 $ hg clone -q -r0 . part2
592 $ hg -q -R part2 pull bundle.hg
595 $ hg -q -R part2 pull bundle.hg
593 $ hg -R part2 verify
596 $ hg -R part2 verify
594 checking changesets
597 checking changesets
595 checking manifests
598 checking manifests
596 crosschecking files in changesets and manifests
599 crosschecking files in changesets and manifests
597 checking files
600 checking files
598 4 files, 3 changesets, 5 total revisions
601 4 files, 3 changesets, 5 total revisions
599
602
600 $ cd ..
603 $ cd ..
@@ -1,8 +1,11 b''
1 hide outer repo
2 $ hg init
3
1 $ echo '[Section]' >> $HGRCPATH
4 $ echo '[Section]' >> $HGRCPATH
2 $ echo 'KeY = Case Sensitive' >> $HGRCPATH
5 $ echo 'KeY = Case Sensitive' >> $HGRCPATH
3 $ echo 'key = lower case' >> $HGRCPATH
6 $ echo 'key = lower case' >> $HGRCPATH
4
7
5 $ hg showconfig Section
8 $ hg showconfig Section
6 Section.KeY=Case Sensitive
9 Section.KeY=Case Sensitive
7 Section.key=lower case
10 Section.key=lower case
8
11
@@ -1,461 +1,461 b''
1
1
2 $ "$TESTDIR/hghave" cvs || exit 80
2 $ "$TESTDIR/hghave" cvs || exit 80
3 $ cvscall()
3 $ cvscall()
4 > {
4 > {
5 > cvs -f "$@"
5 > cvs -f "$@"
6 > }
6 > }
7 $ hgcat()
7 $ hgcat()
8 > {
8 > {
9 > hg --cwd src-hg cat -r tip "$1"
9 > hg --cwd src-hg cat -r tip "$1"
10 > }
10 > }
11 $ echo "[extensions]" >> $HGRCPATH
11 $ echo "[extensions]" >> $HGRCPATH
12 $ echo "convert = " >> $HGRCPATH
12 $ echo "convert = " >> $HGRCPATH
13 $ echo "graphlog = " >> $HGRCPATH
13 $ echo "graphlog = " >> $HGRCPATH
14 $ cat > cvshooks.py <<EOF
14 $ cat > cvshooks.py <<EOF
15 > def cvslog(ui,repo,hooktype,log):
15 > def cvslog(ui,repo,hooktype,log):
16 > print "%s hook: %d entries"%(hooktype,len(log))
16 > print "%s hook: %d entries"%(hooktype,len(log))
17 >
17 >
18 > def cvschangesets(ui,repo,hooktype,changesets):
18 > def cvschangesets(ui,repo,hooktype,changesets):
19 > print "%s hook: %d changesets"%(hooktype,len(changesets))
19 > print "%s hook: %d changesets"%(hooktype,len(changesets))
20 > EOF
20 > EOF
21 $ hookpath=`pwd`
21 $ hookpath=`pwd`
22 $ echo "[hooks]" >> $HGRCPATH
22 $ echo "[hooks]" >> $HGRCPATH
23 $ echo "cvslog=python:$hookpath/cvshooks.py:cvslog" >> $HGRCPATH
23 $ echo "cvslog=python:$hookpath/cvshooks.py:cvslog" >> $HGRCPATH
24 $ echo "cvschangesets=python:$hookpath/cvshooks.py:cvschangesets" >> $HGRCPATH
24 $ echo "cvschangesets=python:$hookpath/cvshooks.py:cvschangesets" >> $HGRCPATH
25
25
26 create cvs repository
26 create cvs repository
27
27
28 $ mkdir cvsrepo
28 $ mkdir cvsrepo
29 $ cd cvsrepo
29 $ cd cvsrepo
30 $ CVSROOT=`pwd`
30 $ CVSROOT=`pwd`
31 $ export CVSROOT
31 $ export CVSROOT
32 $ CVS_OPTIONS=-f
32 $ CVS_OPTIONS=-f
33 $ export CVS_OPTIONS
33 $ export CVS_OPTIONS
34 $ cd ..
34 $ cd ..
35 $ cvscall -q -d "$CVSROOT" init
35 $ cvscall -q -d "$CVSROOT" init
36
36
37 create source directory
37 create source directory
38
38
39 $ mkdir src-temp
39 $ mkdir src-temp
40 $ cd src-temp
40 $ cd src-temp
41 $ echo a > a
41 $ echo a > a
42 $ mkdir b
42 $ mkdir b
43 $ cd b
43 $ cd b
44 $ echo c > c
44 $ echo c > c
45 $ cd ..
45 $ cd ..
46
46
47 import source directory
47 import source directory
48
48
49 $ cvscall -q import -m import src INITIAL start
49 $ cvscall -q import -m import src INITIAL start
50 N src/a
50 N src/a
51 N src/b/c
51 N src/b/c
52
52
53 No conflicts created by this import
53 No conflicts created by this import
54
54
55 $ cd ..
55 $ cd ..
56
56
57 checkout source directory
57 checkout source directory
58
58
59 $ cvscall -q checkout src
59 $ cvscall -q checkout src
60 U src/a
60 U src/a
61 U src/b/c
61 U src/b/c
62
62
63 commit a new revision changing b/c
63 commit a new revision changing b/c
64
64
65 $ cd src
65 $ cd src
66 $ sleep 1
66 $ sleep 1
67 $ echo c >> b/c
67 $ echo c >> b/c
68 $ cvscall -q commit -mci0 . | grep '<--'
68 $ cvscall -q commit -mci0 . | grep '<--'
69 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
69 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
70 $ cd ..
70 $ cd ..
71
71
72 convert fresh repo
72 convert fresh repo
73
73
74 $ hg convert src src-hg
74 $ hg convert src src-hg
75 initializing destination src-hg repository
75 initializing destination src-hg repository
76 connecting to $TESTTMP/cvsrepo
76 connecting to $TESTTMP/cvsrepo
77 scanning source...
77 scanning source...
78 collecting CVS rlog
78 collecting CVS rlog
79 5 log entries
79 5 log entries
80 cvslog hook: 5 entries
80 cvslog hook: 5 entries
81 creating changesets
81 creating changesets
82 3 changeset entries
82 3 changeset entries
83 cvschangesets hook: 3 changesets
83 cvschangesets hook: 3 changesets
84 sorting...
84 sorting...
85 converting...
85 converting...
86 2 Initial revision
86 2 Initial revision
87 1 import
87 1 import
88 0 ci0
88 0 ci0
89 updating tags
89 updating tags
90 $ hgcat a
90 $ hgcat a
91 a
91 a
92 $ hgcat b/c
92 $ hgcat b/c
93 c
93 c
94 c
94 c
95
95
96 convert fresh repo with --filemap
96 convert fresh repo with --filemap
97
97
98 $ echo include b/c > filemap
98 $ echo include b/c > filemap
99 $ hg convert --filemap filemap src src-filemap
99 $ hg convert --filemap filemap src src-filemap
100 initializing destination src-filemap repository
100 initializing destination src-filemap repository
101 connecting to $TESTTMP/cvsrepo
101 connecting to $TESTTMP/cvsrepo
102 scanning source...
102 scanning source...
103 collecting CVS rlog
103 collecting CVS rlog
104 5 log entries
104 5 log entries
105 cvslog hook: 5 entries
105 cvslog hook: 5 entries
106 creating changesets
106 creating changesets
107 3 changeset entries
107 3 changeset entries
108 cvschangesets hook: 3 changesets
108 cvschangesets hook: 3 changesets
109 sorting...
109 sorting...
110 converting...
110 converting...
111 2 Initial revision
111 2 Initial revision
112 1 import
112 1 import
113 filtering out empty revision
113 filtering out empty revision
114 repository tip rolled back to revision 0 (undo commit)
114 repository tip rolled back to revision 0 (undo commit)
115 0 ci0
115 0 ci0
116 updating tags
116 updating tags
117 $ hgcat b/c
117 $ hgcat b/c
118 c
118 c
119 c
119 c
120 $ hg -R src-filemap log --template '{rev} {desc} files: {files}\n'
120 $ hg -R src-filemap log --template '{rev} {desc} files: {files}\n'
121 2 update tags files: .hgtags
121 2 update tags files: .hgtags
122 1 ci0 files: b/c
122 1 ci0 files: b/c
123 0 Initial revision files: b/c
123 0 Initial revision files: b/c
124
124
125 convert full repository (issue1649)
125 convert full repository (issue1649)
126
126
127 $ cvscall -q -d "$CVSROOT" checkout -d srcfull "." | grep -v CVSROOT
127 $ cvscall -q -d "$CVSROOT" checkout -d srcfull "." | grep -v CVSROOT
128 U srcfull/src/a
128 U srcfull/src/a
129 U srcfull/src/b/c
129 U srcfull/src/b/c
130 $ ls srcfull
130 $ ls srcfull
131 CVS
131 CVS
132 CVSROOT
132 CVSROOT
133 src
133 src
134 $ hg convert srcfull srcfull-hg \
134 $ hg convert srcfull srcfull-hg \
135 > | grep -v 'log entries' | grep -v 'hook:' \
135 > | grep -v 'log entries' | grep -v 'hook:' \
136 > | grep -v '^[0-3] .*' # filter instable changeset order
136 > | grep -v '^[0-3] .*' # filter instable changeset order
137 initializing destination srcfull-hg repository
137 initializing destination srcfull-hg repository
138 connecting to $TESTTMP/cvsrepo
138 connecting to $TESTTMP/cvsrepo
139 scanning source...
139 scanning source...
140 collecting CVS rlog
140 collecting CVS rlog
141 creating changesets
141 creating changesets
142 4 changeset entries
142 4 changeset entries
143 sorting...
143 sorting...
144 converting...
144 converting...
145 updating tags
145 updating tags
146 $ hg cat -r tip srcfull-hg/src/a
146 $ hg cat -r tip --cwd srcfull-hg src/a
147 a
147 a
148 $ hg cat -r tip srcfull-hg/src/b/c
148 $ hg cat -r tip --cwd srcfull-hg src/b/c
149 c
149 c
150 c
150 c
151
151
152 commit new file revisions
152 commit new file revisions
153
153
154 $ cd src
154 $ cd src
155 $ echo a >> a
155 $ echo a >> a
156 $ echo c >> b/c
156 $ echo c >> b/c
157 $ cvscall -q commit -mci1 . | grep '<--'
157 $ cvscall -q commit -mci1 . | grep '<--'
158 $TESTTMP/cvsrepo/src/a,v <-- a
158 $TESTTMP/cvsrepo/src/a,v <-- a
159 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
159 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
160 $ cd ..
160 $ cd ..
161
161
162 convert again
162 convert again
163
163
164 $ hg convert src src-hg
164 $ hg convert src src-hg
165 connecting to $TESTTMP/cvsrepo
165 connecting to $TESTTMP/cvsrepo
166 scanning source...
166 scanning source...
167 collecting CVS rlog
167 collecting CVS rlog
168 7 log entries
168 7 log entries
169 cvslog hook: 7 entries
169 cvslog hook: 7 entries
170 creating changesets
170 creating changesets
171 4 changeset entries
171 4 changeset entries
172 cvschangesets hook: 4 changesets
172 cvschangesets hook: 4 changesets
173 sorting...
173 sorting...
174 converting...
174 converting...
175 0 ci1
175 0 ci1
176 $ hgcat a
176 $ hgcat a
177 a
177 a
178 a
178 a
179 $ hgcat b/c
179 $ hgcat b/c
180 c
180 c
181 c
181 c
182 c
182 c
183
183
184 convert again with --filemap
184 convert again with --filemap
185
185
186 $ hg convert --filemap filemap src src-filemap
186 $ hg convert --filemap filemap src src-filemap
187 connecting to $TESTTMP/cvsrepo
187 connecting to $TESTTMP/cvsrepo
188 scanning source...
188 scanning source...
189 collecting CVS rlog
189 collecting CVS rlog
190 7 log entries
190 7 log entries
191 cvslog hook: 7 entries
191 cvslog hook: 7 entries
192 creating changesets
192 creating changesets
193 4 changeset entries
193 4 changeset entries
194 cvschangesets hook: 4 changesets
194 cvschangesets hook: 4 changesets
195 sorting...
195 sorting...
196 converting...
196 converting...
197 0 ci1
197 0 ci1
198 $ hgcat b/c
198 $ hgcat b/c
199 c
199 c
200 c
200 c
201 c
201 c
202 $ hg -R src-filemap log --template '{rev} {desc} files: {files}\n'
202 $ hg -R src-filemap log --template '{rev} {desc} files: {files}\n'
203 3 ci1 files: b/c
203 3 ci1 files: b/c
204 2 update tags files: .hgtags
204 2 update tags files: .hgtags
205 1 ci0 files: b/c
205 1 ci0 files: b/c
206 0 Initial revision files: b/c
206 0 Initial revision files: b/c
207
207
208 commit branch
208 commit branch
209
209
210 $ cd src
210 $ cd src
211 $ cvs -q update -r1.1 b/c
211 $ cvs -q update -r1.1 b/c
212 U b/c
212 U b/c
213 $ cvs -q tag -b branch
213 $ cvs -q tag -b branch
214 T a
214 T a
215 T b/c
215 T b/c
216 $ cvs -q update -r branch > /dev/null
216 $ cvs -q update -r branch > /dev/null
217 $ echo d >> b/c
217 $ echo d >> b/c
218 $ cvs -q commit -mci2 . | grep '<--'
218 $ cvs -q commit -mci2 . | grep '<--'
219 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
219 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
220 $ cd ..
220 $ cd ..
221
221
222 convert again
222 convert again
223
223
224 $ hg convert src src-hg
224 $ hg convert src src-hg
225 connecting to $TESTTMP/cvsrepo
225 connecting to $TESTTMP/cvsrepo
226 scanning source...
226 scanning source...
227 collecting CVS rlog
227 collecting CVS rlog
228 8 log entries
228 8 log entries
229 cvslog hook: 8 entries
229 cvslog hook: 8 entries
230 creating changesets
230 creating changesets
231 5 changeset entries
231 5 changeset entries
232 cvschangesets hook: 5 changesets
232 cvschangesets hook: 5 changesets
233 sorting...
233 sorting...
234 converting...
234 converting...
235 0 ci2
235 0 ci2
236 $ hgcat b/c
236 $ hgcat b/c
237 c
237 c
238 d
238 d
239
239
240 convert again with --filemap
240 convert again with --filemap
241
241
242 $ hg convert --filemap filemap src src-filemap
242 $ hg convert --filemap filemap src src-filemap
243 connecting to $TESTTMP/cvsrepo
243 connecting to $TESTTMP/cvsrepo
244 scanning source...
244 scanning source...
245 collecting CVS rlog
245 collecting CVS rlog
246 8 log entries
246 8 log entries
247 cvslog hook: 8 entries
247 cvslog hook: 8 entries
248 creating changesets
248 creating changesets
249 5 changeset entries
249 5 changeset entries
250 cvschangesets hook: 5 changesets
250 cvschangesets hook: 5 changesets
251 sorting...
251 sorting...
252 converting...
252 converting...
253 0 ci2
253 0 ci2
254 $ hgcat b/c
254 $ hgcat b/c
255 c
255 c
256 d
256 d
257 $ hg -R src-filemap log --template '{rev} {desc} files: {files}\n'
257 $ hg -R src-filemap log --template '{rev} {desc} files: {files}\n'
258 4 ci2 files: b/c
258 4 ci2 files: b/c
259 3 ci1 files: b/c
259 3 ci1 files: b/c
260 2 update tags files: .hgtags
260 2 update tags files: .hgtags
261 1 ci0 files: b/c
261 1 ci0 files: b/c
262 0 Initial revision files: b/c
262 0 Initial revision files: b/c
263
263
264 commit a new revision with funny log message
264 commit a new revision with funny log message
265
265
266 $ cd src
266 $ cd src
267 $ sleep 1
267 $ sleep 1
268 $ echo e >> a
268 $ echo e >> a
269 $ cvscall -q commit -m'funny
269 $ cvscall -q commit -m'funny
270 > ----------------------------
270 > ----------------------------
271 > log message' . | grep '<--' |\
271 > log message' . | grep '<--' |\
272 > sed -e 's:.*src/\(.*\),v.*:checking in src/\1,v:g'
272 > sed -e 's:.*src/\(.*\),v.*:checking in src/\1,v:g'
273 checking in src/a,v
273 checking in src/a,v
274
274
275 commit new file revisions with some fuzz
275 commit new file revisions with some fuzz
276
276
277 $ sleep 1
277 $ sleep 1
278 $ echo f >> a
278 $ echo f >> a
279 $ cvscall -q commit -mfuzzy . | grep '<--'
279 $ cvscall -q commit -mfuzzy . | grep '<--'
280 $TESTTMP/cvsrepo/src/a,v <-- a
280 $TESTTMP/cvsrepo/src/a,v <-- a
281 $ sleep 4 # the two changes will be split if fuzz < 4
281 $ sleep 4 # the two changes will be split if fuzz < 4
282 $ echo g >> b/c
282 $ echo g >> b/c
283 $ cvscall -q commit -mfuzzy . | grep '<--'
283 $ cvscall -q commit -mfuzzy . | grep '<--'
284 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
284 $TESTTMP/cvsrepo/src/b/c,v <-- *c (glob)
285 $ cd ..
285 $ cd ..
286
286
287 convert again
287 convert again
288
288
289 $ hg convert --config convert.cvsps.fuzz=2 src src-hg
289 $ hg convert --config convert.cvsps.fuzz=2 src src-hg
290 connecting to $TESTTMP/cvsrepo
290 connecting to $TESTTMP/cvsrepo
291 scanning source...
291 scanning source...
292 collecting CVS rlog
292 collecting CVS rlog
293 11 log entries
293 11 log entries
294 cvslog hook: 11 entries
294 cvslog hook: 11 entries
295 creating changesets
295 creating changesets
296 8 changeset entries
296 8 changeset entries
297 cvschangesets hook: 8 changesets
297 cvschangesets hook: 8 changesets
298 sorting...
298 sorting...
299 converting...
299 converting...
300 2 funny
300 2 funny
301 1 fuzzy
301 1 fuzzy
302 0 fuzzy
302 0 fuzzy
303 $ hg -R src-hg glog --template '{rev} ({branches}) {desc} files: {files}\n'
303 $ hg -R src-hg glog --template '{rev} ({branches}) {desc} files: {files}\n'
304 o 8 (branch) fuzzy files: b/c
304 o 8 (branch) fuzzy files: b/c
305 |
305 |
306 o 7 (branch) fuzzy files: a
306 o 7 (branch) fuzzy files: a
307 |
307 |
308 o 6 (branch) funny
308 o 6 (branch) funny
309 | ----------------------------
309 | ----------------------------
310 | log message files: a
310 | log message files: a
311 o 5 (branch) ci2 files: b/c
311 o 5 (branch) ci2 files: b/c
312
312
313 o 4 () ci1 files: a b/c
313 o 4 () ci1 files: a b/c
314 |
314 |
315 o 3 () update tags files: .hgtags
315 o 3 () update tags files: .hgtags
316 |
316 |
317 o 2 () ci0 files: b/c
317 o 2 () ci0 files: b/c
318 |
318 |
319 | o 1 (INITIAL) import files:
319 | o 1 (INITIAL) import files:
320 |/
320 |/
321 o 0 () Initial revision files: a b/c
321 o 0 () Initial revision files: a b/c
322
322
323
323
324 testing debugcvsps
324 testing debugcvsps
325
325
326 $ cd src
326 $ cd src
327 $ hg debugcvsps --fuzz=2
327 $ hg debugcvsps --fuzz=2
328 collecting CVS rlog
328 collecting CVS rlog
329 11 log entries
329 11 log entries
330 cvslog hook: 11 entries
330 cvslog hook: 11 entries
331 creating changesets
331 creating changesets
332 10 changeset entries
332 10 changeset entries
333 cvschangesets hook: 10 changesets
333 cvschangesets hook: 10 changesets
334 ---------------------
334 ---------------------
335 PatchSet 1
335 PatchSet 1
336 Date: * (glob)
336 Date: * (glob)
337 Author: * (glob)
337 Author: * (glob)
338 Branch: HEAD
338 Branch: HEAD
339 Tag: (none)
339 Tag: (none)
340 Branchpoints: INITIAL
340 Branchpoints: INITIAL
341 Log:
341 Log:
342 Initial revision
342 Initial revision
343
343
344 Members:
344 Members:
345 a:INITIAL->1.1
345 a:INITIAL->1.1
346
346
347 ---------------------
347 ---------------------
348 PatchSet 2
348 PatchSet 2
349 Date: * (glob)
349 Date: * (glob)
350 Author: * (glob)
350 Author: * (glob)
351 Branch: HEAD
351 Branch: HEAD
352 Tag: (none)
352 Tag: (none)
353 Branchpoints: INITIAL, branch
353 Branchpoints: INITIAL, branch
354 Log:
354 Log:
355 Initial revision
355 Initial revision
356
356
357 Members:
357 Members:
358 b/c:INITIAL->1.1
358 b/c:INITIAL->1.1
359
359
360 ---------------------
360 ---------------------
361 PatchSet 3
361 PatchSet 3
362 Date: * (glob)
362 Date: * (glob)
363 Author: * (glob)
363 Author: * (glob)
364 Branch: INITIAL
364 Branch: INITIAL
365 Tag: start
365 Tag: start
366 Log:
366 Log:
367 import
367 import
368
368
369 Members:
369 Members:
370 a:1.1->1.1.1.1
370 a:1.1->1.1.1.1
371 b/c:1.1->1.1.1.1
371 b/c:1.1->1.1.1.1
372
372
373 ---------------------
373 ---------------------
374 PatchSet 4
374 PatchSet 4
375 Date: * (glob)
375 Date: * (glob)
376 Author: * (glob)
376 Author: * (glob)
377 Branch: HEAD
377 Branch: HEAD
378 Tag: (none)
378 Tag: (none)
379 Log:
379 Log:
380 ci0
380 ci0
381
381
382 Members:
382 Members:
383 b/c:1.1->1.2
383 b/c:1.1->1.2
384
384
385 ---------------------
385 ---------------------
386 PatchSet 5
386 PatchSet 5
387 Date: * (glob)
387 Date: * (glob)
388 Author: * (glob)
388 Author: * (glob)
389 Branch: HEAD
389 Branch: HEAD
390 Tag: (none)
390 Tag: (none)
391 Branchpoints: branch
391 Branchpoints: branch
392 Log:
392 Log:
393 ci1
393 ci1
394
394
395 Members:
395 Members:
396 a:1.1->1.2
396 a:1.1->1.2
397
397
398 ---------------------
398 ---------------------
399 PatchSet 6
399 PatchSet 6
400 Date: * (glob)
400 Date: * (glob)
401 Author: * (glob)
401 Author: * (glob)
402 Branch: HEAD
402 Branch: HEAD
403 Tag: (none)
403 Tag: (none)
404 Log:
404 Log:
405 ci1
405 ci1
406
406
407 Members:
407 Members:
408 b/c:1.2->1.3
408 b/c:1.2->1.3
409
409
410 ---------------------
410 ---------------------
411 PatchSet 7
411 PatchSet 7
412 Date: * (glob)
412 Date: * (glob)
413 Author: * (glob)
413 Author: * (glob)
414 Branch: branch
414 Branch: branch
415 Tag: (none)
415 Tag: (none)
416 Log:
416 Log:
417 ci2
417 ci2
418
418
419 Members:
419 Members:
420 b/c:1.1->1.1.2.1
420 b/c:1.1->1.1.2.1
421
421
422 ---------------------
422 ---------------------
423 PatchSet 8
423 PatchSet 8
424 Date: * (glob)
424 Date: * (glob)
425 Author: * (glob)
425 Author: * (glob)
426 Branch: branch
426 Branch: branch
427 Tag: (none)
427 Tag: (none)
428 Log:
428 Log:
429 funny
429 funny
430 ----------------------------
430 ----------------------------
431 log message
431 log message
432
432
433 Members:
433 Members:
434 a:1.2->1.2.2.1
434 a:1.2->1.2.2.1
435
435
436 ---------------------
436 ---------------------
437 PatchSet 9
437 PatchSet 9
438 Date: * (glob)
438 Date: * (glob)
439 Author: * (glob)
439 Author: * (glob)
440 Branch: branch
440 Branch: branch
441 Tag: (none)
441 Tag: (none)
442 Log:
442 Log:
443 fuzzy
443 fuzzy
444
444
445 Members:
445 Members:
446 a:1.2.2.1->1.2.2.2
446 a:1.2.2.1->1.2.2.2
447
447
448 ---------------------
448 ---------------------
449 PatchSet 10
449 PatchSet 10
450 Date: * (glob)
450 Date: * (glob)
451 Author: * (glob)
451 Author: * (glob)
452 Branch: branch
452 Branch: branch
453 Tag: (none)
453 Tag: (none)
454 Log:
454 Log:
455 fuzzy
455 fuzzy
456
456
457 Members:
457 Members:
458 b/c:1.1.2.1->1.1.2.2
458 b/c:1.1.2.1->1.1.2.2
459
459
460
460
461 $ cd ..
461 $ cd ..
@@ -1,106 +1,110 b''
1
1
2 $ "$TESTDIR/hghave" darcs || exit 80
2 $ "$TESTDIR/hghave" darcs || exit 80
3 $ echo "[extensions]" >> $HGRCPATH
3 $ echo "[extensions]" >> $HGRCPATH
4 $ echo "convert=" >> $HGRCPATH
4 $ echo "convert=" >> $HGRCPATH
5 $ echo 'graphlog =' >> $HGRCPATH
5 $ echo 'graphlog =' >> $HGRCPATH
6 $ DARCS_EMAIL='test@example.org'; export DARCS_EMAIL
6 $ DARCS_EMAIL='test@example.org'; export DARCS_EMAIL
7
7
8 skip if we can't import elementtree
8 skip if we can't import elementtree
9
9
10 $ mkdir dummy
10 $ mkdir dummy
11 $ mkdir dummy/_darcs
11 $ mkdir dummy/_darcs
12 $ if hg convert dummy 2>&1 | grep ElementTree > /dev/null; then
12 $ if hg convert dummy 2>&1 | grep ElementTree > /dev/null; then
13 > echo 'skipped: missing feature: elementtree module'
13 > echo 'skipped: missing feature: elementtree module'
14 > exit 80
14 > exit 80
15 > fi
15 > fi
16
16
17 #if no-outer-repo
18
17 try converting darcs1 repository
19 try converting darcs1 repository
18
20
19 $ hg clone -q "$TESTDIR/bundles/darcs1.hg" darcs
21 $ hg clone -q "$TESTDIR/bundles/darcs1.hg" darcs
20 $ hg convert -s darcs darcs/darcs1 2>&1 | grep darcs-1.0
22 $ hg convert -s darcs darcs/darcs1 2>&1 | grep darcs-1.0
21 darcs-1.0 repository format is unsupported, please upgrade
23 darcs-1.0 repository format is unsupported, please upgrade
22
24
25 #endif
26
23 initialize darcs repo
27 initialize darcs repo
24
28
25 $ mkdir darcs-repo
29 $ mkdir darcs-repo
26 $ cd darcs-repo
30 $ cd darcs-repo
27 $ darcs init
31 $ darcs init
28 $ echo a > a
32 $ echo a > a
29 $ darcs record -a -l -m p0
33 $ darcs record -a -l -m p0
30 Finished recording patch 'p0'
34 Finished recording patch 'p0'
31 $ cd ..
35 $ cd ..
32
36
33 branch and update
37 branch and update
34
38
35 $ darcs get -q darcs-repo darcs-clone >/dev/null
39 $ darcs get -q darcs-repo darcs-clone >/dev/null
36 $ cd darcs-clone
40 $ cd darcs-clone
37 $ echo c >> a
41 $ echo c >> a
38 $ echo c > c
42 $ echo c > c
39 $ darcs record -a -l -m p1.1
43 $ darcs record -a -l -m p1.1
40 Finished recording patch 'p1.1'
44 Finished recording patch 'p1.1'
41 $ cd ..
45 $ cd ..
42
46
43 update source
47 update source
44
48
45 $ cd darcs-repo
49 $ cd darcs-repo
46 $ echo b >> a
50 $ echo b >> a
47 $ echo b > b
51 $ echo b > b
48 $ darcs record -a -l -m p1.2
52 $ darcs record -a -l -m p1.2
49 Finished recording patch 'p1.2'
53 Finished recording patch 'p1.2'
50
54
51 $ darcs pull -q -a --no-set-default ../darcs-clone
55 $ darcs pull -q -a --no-set-default ../darcs-clone
52 Backing up ./a(*) (glob)
56 Backing up ./a(*) (glob)
53 We have conflicts in the following files:
57 We have conflicts in the following files:
54 ./a
58 ./a
55 $ sleep 1
59 $ sleep 1
56 $ echo e > a
60 $ echo e > a
57 $ echo f > f
61 $ echo f > f
58 $ mkdir dir
62 $ mkdir dir
59 $ echo d > dir/d
63 $ echo d > dir/d
60 $ echo d > dir/d2
64 $ echo d > dir/d2
61 $ darcs record -a -l -m p2
65 $ darcs record -a -l -m p2
62 Finished recording patch 'p2'
66 Finished recording patch 'p2'
63
67
64 test file and directory move
68 test file and directory move
65
69
66 $ darcs mv f ff
70 $ darcs mv f ff
67
71
68 Test remove + move
72 Test remove + move
69
73
70 $ darcs remove dir/d2
74 $ darcs remove dir/d2
71 $ rm dir/d2
75 $ rm dir/d2
72 $ darcs mv dir dir2
76 $ darcs mv dir dir2
73 $ darcs record -a -l -m p3
77 $ darcs record -a -l -m p3
74 Finished recording patch 'p3'
78 Finished recording patch 'p3'
75
79
76 The converter does not currently handle patch conflicts very well.
80 The converter does not currently handle patch conflicts very well.
77 When they occur, it reverts *all* changes and moves forward,
81 When they occur, it reverts *all* changes and moves forward,
78 letting the conflict resolving patch fix collisions.
82 letting the conflict resolving patch fix collisions.
79 Unfortunately, non-conflicting changes, like the addition of the
83 Unfortunately, non-conflicting changes, like the addition of the
80 "c" file in p1.1 patch are reverted too.
84 "c" file in p1.1 patch are reverted too.
81 Just to say that manifest not listing "c" here is a bug.
85 Just to say that manifest not listing "c" here is a bug.
82
86
83 $ cd ..
87 $ cd ..
84 $ hg convert darcs-repo darcs-repo-hg
88 $ hg convert darcs-repo darcs-repo-hg
85 initializing destination darcs-repo-hg repository
89 initializing destination darcs-repo-hg repository
86 scanning source...
90 scanning source...
87 sorting...
91 sorting...
88 converting...
92 converting...
89 4 p0
93 4 p0
90 3 p1.2
94 3 p1.2
91 2 p1.1
95 2 p1.1
92 1 p2
96 1 p2
93 0 p3
97 0 p3
94 $ hg log -R darcs-repo-hg -g --template '{rev} "{desc|firstline}" ({author}) files: {files}\n' "$@"
98 $ hg log -R darcs-repo-hg -g --template '{rev} "{desc|firstline}" ({author}) files: {files}\n' "$@"
95 4 "p3" (test@example.org) files: dir/d dir/d2 dir2/d f ff
99 4 "p3" (test@example.org) files: dir/d dir/d2 dir2/d f ff
96 3 "p2" (test@example.org) files: a dir/d dir/d2 f
100 3 "p2" (test@example.org) files: a dir/d dir/d2 f
97 2 "p1.1" (test@example.org) files:
101 2 "p1.1" (test@example.org) files:
98 1 "p1.2" (test@example.org) files: a b
102 1 "p1.2" (test@example.org) files: a b
99 0 "p0" (test@example.org) files: a
103 0 "p0" (test@example.org) files: a
100
104
101 $ hg up -q -R darcs-repo-hg
105 $ hg up -q -R darcs-repo-hg
102 $ hg -R darcs-repo-hg manifest --debug
106 $ hg -R darcs-repo-hg manifest --debug
103 7225b30cdf38257d5cc7780772c051b6f33e6d6b 644 a
107 7225b30cdf38257d5cc7780772c051b6f33e6d6b 644 a
104 1e88685f5ddec574a34c70af492f95b6debc8741 644 b
108 1e88685f5ddec574a34c70af492f95b6debc8741 644 b
105 37406831adc447ec2385014019599dfec953c806 644 dir2/d
109 37406831adc447ec2385014019599dfec953c806 644 dir2/d
106 b783a337463792a5c7d548ad85a7d3253c16ba8c 644 ff
110 b783a337463792a5c7d548ad85a7d3253c16ba8c 644 ff
@@ -1,194 +1,203 b''
1 hide outer repo
2 $ hg init
3
1 Use hgrc within $TESTTMP
4 Use hgrc within $TESTTMP
2
5
3 $ HGRCPATH=`pwd`/hgrc
6 $ HGRCPATH=`pwd`/hgrc
4 $ export HGRCPATH
7 $ export HGRCPATH
5
8
6 Use an alternate var for scribbling on hgrc to keep check-code from
9 Use an alternate var for scribbling on hgrc to keep check-code from
7 complaining about the important settings we may be overwriting:
10 complaining about the important settings we may be overwriting:
8
11
9 $ HGRC=`pwd`/hgrc
12 $ HGRC=`pwd`/hgrc
10 $ export HGRC
13 $ export HGRC
11
14
12 Basic syntax error
15 Basic syntax error
13
16
14 $ echo "invalid" > $HGRC
17 $ echo "invalid" > $HGRC
15 $ hg version
18 $ hg version
16 hg: parse error at $TESTTMP/hgrc:1: invalid
19 hg: parse error at $TESTTMP/hgrc:1: invalid
17 [255]
20 [255]
18 $ echo "" > $HGRC
21 $ echo "" > $HGRC
19
22
20 Issue1199: Can't use '%' in hgrc (eg url encoded username)
23 Issue1199: Can't use '%' in hgrc (eg url encoded username)
21
24
22 $ hg init "foo%bar"
25 $ hg init "foo%bar"
23 $ hg clone "foo%bar" foobar
26 $ hg clone "foo%bar" foobar
24 updating to branch default
27 updating to branch default
25 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
28 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
26 $ cd foobar
29 $ cd foobar
27 $ cat .hg/hgrc
30 $ cat .hg/hgrc
28 [paths]
31 [paths]
29 default = $TESTTMP/foo%bar (glob)
32 default = $TESTTMP/foo%bar (glob)
30 $ hg paths
33 $ hg paths
31 default = $TESTTMP/foo%bar (glob)
34 default = $TESTTMP/foo%bar (glob)
32 $ hg showconfig
35 $ hg showconfig
33 bundle.mainreporoot=$TESTTMP/foobar (glob)
36 bundle.mainreporoot=$TESTTMP/foobar (glob)
34 paths.default=$TESTTMP/foo%bar (glob)
37 paths.default=$TESTTMP/foo%bar (glob)
35 $ cd ..
38 $ cd ..
36
39
37 issue1829: wrong indentation
40 issue1829: wrong indentation
38
41
39 $ echo '[foo]' > $HGRC
42 $ echo '[foo]' > $HGRC
40 $ echo ' x = y' >> $HGRC
43 $ echo ' x = y' >> $HGRC
41 $ hg version
44 $ hg version
42 hg: parse error at $TESTTMP/hgrc:2: x = y
45 hg: parse error at $TESTTMP/hgrc:2: x = y
43 [255]
46 [255]
44
47
45 $ python -c "print '[foo]\nbar = a\n b\n c \n de\n fg \nbaz = bif cb \n'" \
48 $ python -c "print '[foo]\nbar = a\n b\n c \n de\n fg \nbaz = bif cb \n'" \
46 > > $HGRC
49 > > $HGRC
47 $ hg showconfig foo
50 $ hg showconfig foo
48 foo.bar=a\nb\nc\nde\nfg
51 foo.bar=a\nb\nc\nde\nfg
49 foo.baz=bif cb
52 foo.baz=bif cb
50
53
51 $ FAKEPATH=/path/to/nowhere
54 $ FAKEPATH=/path/to/nowhere
52 $ export FAKEPATH
55 $ export FAKEPATH
53 $ echo '%include $FAKEPATH/no-such-file' > $HGRC
56 $ echo '%include $FAKEPATH/no-such-file' > $HGRC
54 $ hg version
57 $ hg version
55 Mercurial Distributed SCM (version *) (glob)
58 Mercurial Distributed SCM (version *) (glob)
56 (see http://mercurial.selenic.com for more information)
59 (see http://mercurial.selenic.com for more information)
57
60
58 Copyright (C) 2005-2012 Matt Mackall and others
61 Copyright (C) 2005-2012 Matt Mackall and others
59 This is free software; see the source for copying conditions. There is NO
62 This is free software; see the source for copying conditions. There is NO
60 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
63 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
61 $ unset FAKEPATH
64 $ unset FAKEPATH
62
65
63 make sure global options given on the cmdline take precedence
66 make sure global options given on the cmdline take precedence
64
67
65 $ hg showconfig --config ui.verbose=True --quiet
68 $ hg showconfig --config ui.verbose=True --quiet
69 bundle.mainreporoot=$TESTTMP
66 ui.verbose=False
70 ui.verbose=False
67 ui.debug=False
71 ui.debug=False
68 ui.quiet=True
72 ui.quiet=True
69
73
70 $ touch foobar/untracked
74 $ touch foobar/untracked
71 $ cat >> foobar/.hg/hgrc <<EOF
75 $ cat >> foobar/.hg/hgrc <<EOF
72 > [ui]
76 > [ui]
73 > verbose=True
77 > verbose=True
74 > EOF
78 > EOF
75 $ hg -R foobar st -q
79 $ hg -R foobar st -q
76
80
77 username expansion
81 username expansion
78
82
79 $ olduser=$HGUSER
83 $ olduser=$HGUSER
80 $ unset HGUSER
84 $ unset HGUSER
81
85
82 $ FAKEUSER='John Doe'
86 $ FAKEUSER='John Doe'
83 $ export FAKEUSER
87 $ export FAKEUSER
84 $ echo '[ui]' > $HGRC
88 $ echo '[ui]' > $HGRC
85 $ echo 'username = $FAKEUSER' >> $HGRC
89 $ echo 'username = $FAKEUSER' >> $HGRC
86
90
87 $ hg init usertest
91 $ hg init usertest
88 $ cd usertest
92 $ cd usertest
89 $ touch bar
93 $ touch bar
90 $ hg commit --addremove --quiet -m "added bar"
94 $ hg commit --addremove --quiet -m "added bar"
91 $ hg log --template "{author}\n"
95 $ hg log --template "{author}\n"
92 John Doe
96 John Doe
93 $ cd ..
97 $ cd ..
94
98
95 $ hg showconfig
99 $ hg showconfig
100 bundle.mainreporoot=$TESTTMP
96 ui.username=$FAKEUSER
101 ui.username=$FAKEUSER
97
102
98 $ unset FAKEUSER
103 $ unset FAKEUSER
99 $ HGUSER=$olduser
104 $ HGUSER=$olduser
100 $ export HGUSER
105 $ export HGUSER
101
106
102 showconfig with multiple arguments
107 showconfig with multiple arguments
103
108
104 $ echo "[alias]" > $HGRC
109 $ echo "[alias]" > $HGRC
105 $ echo "log = log -g" >> $HGRC
110 $ echo "log = log -g" >> $HGRC
106 $ echo "[defaults]" >> $HGRC
111 $ echo "[defaults]" >> $HGRC
107 $ echo "identify = -n" >> $HGRC
112 $ echo "identify = -n" >> $HGRC
108 $ hg showconfig alias defaults
113 $ hg showconfig alias defaults
109 alias.log=log -g
114 alias.log=log -g
110 defaults.identify=-n
115 defaults.identify=-n
111 $ hg showconfig alias defaults.identify
116 $ hg showconfig alias defaults.identify
112 abort: only one config item permitted
117 abort: only one config item permitted
113 [255]
118 [255]
114 $ hg showconfig alias.log defaults.identify
119 $ hg showconfig alias.log defaults.identify
115 abort: only one config item permitted
120 abort: only one config item permitted
116 [255]
121 [255]
117
122
118 HGPLAIN
123 HGPLAIN
119
124
120 $ p=`pwd`
121 $ echo "[ui]" > $HGRC
125 $ echo "[ui]" > $HGRC
122 $ echo "debug=true" >> $HGRC
126 $ echo "debug=true" >> $HGRC
123 $ echo "fallbackencoding=ASCII" >> $HGRC
127 $ echo "fallbackencoding=ASCII" >> $HGRC
124 $ echo "quiet=true" >> $HGRC
128 $ echo "quiet=true" >> $HGRC
125 $ echo "slash=true" >> $HGRC
129 $ echo "slash=true" >> $HGRC
126 $ echo "traceback=true" >> $HGRC
130 $ echo "traceback=true" >> $HGRC
127 $ echo "verbose=true" >> $HGRC
131 $ echo "verbose=true" >> $HGRC
128 $ echo "style=~/.hgstyle" >> $HGRC
132 $ echo "style=~/.hgstyle" >> $HGRC
129 $ echo "logtemplate={node}" >> $HGRC
133 $ echo "logtemplate={node}" >> $HGRC
130 $ echo "[defaults]" >> $HGRC
134 $ echo "[defaults]" >> $HGRC
131 $ echo "identify=-n" >> $HGRC
135 $ echo "identify=-n" >> $HGRC
132 $ echo "[alias]" >> $HGRC
136 $ echo "[alias]" >> $HGRC
133 $ echo "log=log -g" >> $HGRC
137 $ echo "log=log -g" >> $HGRC
134
138
135 customized hgrc
139 customized hgrc
136
140
137 $ hg showconfig
141 $ hg showconfig
138 read config from: $TESTTMP/hgrc
142 read config from: $TESTTMP/hgrc
139 $TESTTMP/hgrc:13: alias.log=log -g
143 $TESTTMP/hgrc:13: alias.log=log -g
144 none: bundle.mainreporoot=$TESTTMP
140 $TESTTMP/hgrc:11: defaults.identify=-n
145 $TESTTMP/hgrc:11: defaults.identify=-n
141 $TESTTMP/hgrc:2: ui.debug=true
146 $TESTTMP/hgrc:2: ui.debug=true
142 $TESTTMP/hgrc:3: ui.fallbackencoding=ASCII
147 $TESTTMP/hgrc:3: ui.fallbackencoding=ASCII
143 $TESTTMP/hgrc:4: ui.quiet=true
148 $TESTTMP/hgrc:4: ui.quiet=true
144 $TESTTMP/hgrc:5: ui.slash=true
149 $TESTTMP/hgrc:5: ui.slash=true
145 $TESTTMP/hgrc:6: ui.traceback=true
150 $TESTTMP/hgrc:6: ui.traceback=true
146 $TESTTMP/hgrc:7: ui.verbose=true
151 $TESTTMP/hgrc:7: ui.verbose=true
147 $TESTTMP/hgrc:8: ui.style=~/.hgstyle
152 $TESTTMP/hgrc:8: ui.style=~/.hgstyle
148 $TESTTMP/hgrc:9: ui.logtemplate={node}
153 $TESTTMP/hgrc:9: ui.logtemplate={node}
149
154
150 plain hgrc
155 plain hgrc
151
156
152 $ HGPLAIN=; export HGPLAIN
157 $ HGPLAIN=; export HGPLAIN
153 $ hg showconfig --config ui.traceback=True --debug
158 $ hg showconfig --config ui.traceback=True --debug
154 read config from: $TESTTMP/hgrc
159 read config from: $TESTTMP/hgrc
160 none: bundle.mainreporoot=$TESTTMP
155 none: ui.traceback=True
161 none: ui.traceback=True
156 none: ui.verbose=False
162 none: ui.verbose=False
157 none: ui.debug=True
163 none: ui.debug=True
158 none: ui.quiet=False
164 none: ui.quiet=False
159
165
160 plain mode with exceptions
166 plain mode with exceptions
161
167
162 $ cat > plain.py <<EOF
168 $ cat > plain.py <<EOF
163 > def uisetup(ui):
169 > def uisetup(ui):
164 > ui.write('plain: %r\n' % ui.plain())
170 > ui.write('plain: %r\n' % ui.plain())
165 > EOF
171 > EOF
166 $ echo "[extensions]" >> $HGRC
172 $ echo "[extensions]" >> $HGRC
167 $ echo "plain=./plain.py" >> $HGRC
173 $ echo "plain=./plain.py" >> $HGRC
168 $ HGPLAINEXCEPT=; export HGPLAINEXCEPT
174 $ HGPLAINEXCEPT=; export HGPLAINEXCEPT
169 $ hg showconfig --config ui.traceback=True --debug
175 $ hg showconfig --config ui.traceback=True --debug
170 plain: True
176 plain: True
171 read config from: $TESTTMP/hgrc
177 read config from: $TESTTMP/hgrc
178 none: bundle.mainreporoot=$TESTTMP
172 $TESTTMP/hgrc:15: extensions.plain=./plain.py
179 $TESTTMP/hgrc:15: extensions.plain=./plain.py
173 none: ui.traceback=True
180 none: ui.traceback=True
174 none: ui.verbose=False
181 none: ui.verbose=False
175 none: ui.debug=True
182 none: ui.debug=True
176 none: ui.quiet=False
183 none: ui.quiet=False
177 $ unset HGPLAIN
184 $ unset HGPLAIN
178 $ hg showconfig --config ui.traceback=True --debug
185 $ hg showconfig --config ui.traceback=True --debug
179 plain: True
186 plain: True
180 read config from: $TESTTMP/hgrc
187 read config from: $TESTTMP/hgrc
188 none: bundle.mainreporoot=$TESTTMP
181 $TESTTMP/hgrc:15: extensions.plain=./plain.py
189 $TESTTMP/hgrc:15: extensions.plain=./plain.py
182 none: ui.traceback=True
190 none: ui.traceback=True
183 none: ui.verbose=False
191 none: ui.verbose=False
184 none: ui.debug=True
192 none: ui.debug=True
185 none: ui.quiet=False
193 none: ui.quiet=False
186 $ HGPLAINEXCEPT=i18n; export HGPLAINEXCEPT
194 $ HGPLAINEXCEPT=i18n; export HGPLAINEXCEPT
187 $ hg showconfig --config ui.traceback=True --debug
195 $ hg showconfig --config ui.traceback=True --debug
188 plain: True
196 plain: True
189 read config from: $TESTTMP/hgrc
197 read config from: $TESTTMP/hgrc
198 none: bundle.mainreporoot=$TESTTMP
190 $TESTTMP/hgrc:15: extensions.plain=./plain.py
199 $TESTTMP/hgrc:15: extensions.plain=./plain.py
191 none: ui.traceback=True
200 none: ui.traceback=True
192 none: ui.verbose=False
201 none: ui.verbose=False
193 none: ui.debug=True
202 none: ui.debug=True
194 none: ui.quiet=False
203 none: ui.quiet=False
@@ -1,1008 +1,1015 b''
1 $ "$TESTDIR/hghave" serve || exit 80
1 $ "$TESTDIR/hghave" serve || exit 80
2
2
3 hide outer repo and work in dir without '.hg'
4 $ hg init
5 $ mkdir dir
6 $ cd dir
7
3 Tests some basic hgwebdir functionality. Tests setting up paths and
8 Tests some basic hgwebdir functionality. Tests setting up paths and
4 collection, different forms of 404s and the subdirectory support.
9 collection, different forms of 404s and the subdirectory support.
5
10
6 $ mkdir webdir
11 $ mkdir webdir
7 $ cd webdir
12 $ cd webdir
8 $ hg init a
13 $ hg init a
9 $ echo a > a/a
14 $ echo a > a/a
10 $ hg --cwd a ci -Ama -d'1 0'
15 $ hg --cwd a ci -Ama -d'1 0'
11 adding a
16 adding a
12
17
13 create a mercurial queue repository
18 create a mercurial queue repository
14
19
15 $ hg --cwd a qinit --config extensions.hgext.mq= -c
20 $ hg --cwd a qinit --config extensions.hgext.mq= -c
16 $ hg init b
21 $ hg init b
17 $ echo b > b/b
22 $ echo b > b/b
18 $ hg --cwd b ci -Amb -d'2 0'
23 $ hg --cwd b ci -Amb -d'2 0'
19 adding b
24 adding b
20
25
21 create a nested repository
26 create a nested repository
22
27
23 $ cd b
28 $ cd b
24 $ hg init d
29 $ hg init d
25 $ echo d > d/d
30 $ echo d > d/d
26 $ hg --cwd d ci -Amd -d'3 0'
31 $ hg --cwd d ci -Amd -d'3 0'
27 adding d
32 adding d
28 $ cd ..
33 $ cd ..
29 $ hg init c
34 $ hg init c
30 $ echo c > c/c
35 $ echo c > c/c
31 $ hg --cwd c ci -Amc -d'3 0'
36 $ hg --cwd c ci -Amc -d'3 0'
32 adding c
37 adding c
33
38
34 create a subdirectory containing repositories and subrepositories
39 create a subdirectory containing repositories and subrepositories
35
40
36 $ mkdir notrepo
41 $ mkdir notrepo
37 $ cd notrepo
42 $ cd notrepo
38 $ hg init e
43 $ hg init e
39 $ echo e > e/e
44 $ echo e > e/e
40 $ hg --cwd e ci -Ame -d'4 0'
45 $ hg --cwd e ci -Ame -d'4 0'
41 adding e
46 adding e
42 $ hg init e/e2
47 $ hg init e/e2
43 $ echo e2 > e/e2/e2
48 $ echo e2 > e/e2/e2
44 $ hg --cwd e/e2 ci -Ame2 -d '4 0'
49 $ hg --cwd e/e2 ci -Ame2 -d '4 0'
45 adding e2
50 adding e2
46 $ hg init f
51 $ hg init f
47 $ echo f > f/f
52 $ echo f > f/f
48 $ hg --cwd f ci -Amf -d'4 0'
53 $ hg --cwd f ci -Amf -d'4 0'
49 adding f
54 adding f
50 $ hg init f/f2
55 $ hg init f/f2
51 $ echo f2 > f/f2/f2
56 $ echo f2 > f/f2/f2
52 $ hg --cwd f/f2 ci -Amf2 -d '4 0'
57 $ hg --cwd f/f2 ci -Amf2 -d '4 0'
53 adding f2
58 adding f2
54 $ cd ..
59 $ cd ..
55
60
56 create repository without .hg/store
61 create repository without .hg/store
57
62
58 $ hg init nostore
63 $ hg init nostore
59 $ rm -R nostore/.hg/store
64 $ rm -R nostore/.hg/store
60 $ root=`pwd`
65 $ root=`pwd`
61 $ cd ..
66 $ cd ..
67
68 serve
62 $ cat > paths.conf <<EOF
69 $ cat > paths.conf <<EOF
63 > [paths]
70 > [paths]
64 > a=$root/a
71 > a=$root/a
65 > b=$root/b
72 > b=$root/b
66 > EOF
73 > EOF
67 $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf paths.conf \
74 $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf paths.conf \
68 > -A access-paths.log -E error-paths-1.log
75 > -A access-paths.log -E error-paths-1.log
69 $ cat hg.pid >> $DAEMON_PIDS
76 $ cat hg.pid >> $DAEMON_PIDS
70
77
71 should give a 404 - file does not exist
78 should give a 404 - file does not exist
72
79
73 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/file/tip/bork?style=raw'
80 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/file/tip/bork?style=raw'
74 404 Not Found
81 404 Not Found
75
82
76
83
77 error: bork@8580ff50825a: not found in manifest
84 error: bork@8580ff50825a: not found in manifest
78 [1]
85 [1]
79
86
80 should succeed
87 should succeed
81
88
82 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
89 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
83 200 Script output follows
90 200 Script output follows
84
91
85
92
86 /a/
93 /a/
87 /b/
94 /b/
88
95
89 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/file/tip/a?style=raw'
96 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/file/tip/a?style=raw'
90 200 Script output follows
97 200 Script output follows
91
98
92 a
99 a
93 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/b/file/tip/b?style=raw'
100 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/b/file/tip/b?style=raw'
94 200 Script output follows
101 200 Script output follows
95
102
96 b
103 b
97
104
98 should give a 404 - repo is not published
105 should give a 404 - repo is not published
99
106
100 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/c/file/tip/c?style=raw'
107 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/c/file/tip/c?style=raw'
101 404 Not Found
108 404 Not Found
102
109
103
110
104 error: repository c/file/tip/c not found
111 error: repository c/file/tip/c not found
105 [1]
112 [1]
106
113
107 atom-log without basedir
114 atom-log without basedir
108
115
109 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/atom-log' | grep '<link'
116 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/atom-log' | grep '<link'
110 <link rel="self" href="http://*:$HGPORT/a/atom-log"/> (glob)
117 <link rel="self" href="http://*:$HGPORT/a/atom-log"/> (glob)
111 <link rel="alternate" href="http://*:$HGPORT/a/"/> (glob)
118 <link rel="alternate" href="http://*:$HGPORT/a/"/> (glob)
112 <link href="http://*:$HGPORT/a/rev/8580ff50825a"/> (glob)
119 <link href="http://*:$HGPORT/a/rev/8580ff50825a"/> (glob)
113
120
114 rss-log without basedir
121 rss-log without basedir
115
122
116 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/rss-log' | grep '<guid'
123 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/a/rss-log' | grep '<guid'
117 <guid isPermaLink="true">http://*:$HGPORT/a/rev/8580ff50825a</guid> (glob)
124 <guid isPermaLink="true">http://*:$HGPORT/a/rev/8580ff50825a</guid> (glob)
118 $ cat > paths.conf <<EOF
125 $ cat > paths.conf <<EOF
119 > [paths]
126 > [paths]
120 > t/a/=$root/a
127 > t/a/=$root/a
121 > b=$root/b
128 > b=$root/b
122 > coll=$root/*
129 > coll=$root/*
123 > rcoll=$root/**
130 > rcoll=$root/**
124 > star=*
131 > star=*
125 > starstar=**
132 > starstar=**
126 > astar=webdir/a/*
133 > astar=webdir/a/*
127 > EOF
134 > EOF
128 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
135 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
129 > -A access-paths.log -E error-paths-2.log
136 > -A access-paths.log -E error-paths-2.log
130 $ cat hg.pid >> $DAEMON_PIDS
137 $ cat hg.pid >> $DAEMON_PIDS
131
138
132 should succeed, slashy names
139 should succeed, slashy names
133
140
134 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
141 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
135 200 Script output follows
142 200 Script output follows
136
143
137
144
138 /t/a/
145 /t/a/
139 /b/
146 /b/
140 /coll/a/
147 /coll/a/
141 /coll/a/.hg/patches/
148 /coll/a/.hg/patches/
142 /coll/b/
149 /coll/b/
143 /coll/c/
150 /coll/c/
144 /coll/notrepo/e/
151 /coll/notrepo/e/
145 /coll/notrepo/f/
152 /coll/notrepo/f/
146 /rcoll/a/
153 /rcoll/a/
147 /rcoll/a/.hg/patches/
154 /rcoll/a/.hg/patches/
148 /rcoll/b/
155 /rcoll/b/
149 /rcoll/b/d/
156 /rcoll/b/d/
150 /rcoll/c/
157 /rcoll/c/
151 /rcoll/notrepo/e/
158 /rcoll/notrepo/e/
152 /rcoll/notrepo/e/e2/
159 /rcoll/notrepo/e/e2/
153 /rcoll/notrepo/f/
160 /rcoll/notrepo/f/
154 /rcoll/notrepo/f/f2/
161 /rcoll/notrepo/f/f2/
155 /star/webdir/a/
162 /star/webdir/a/
156 /star/webdir/a/.hg/patches/
163 /star/webdir/a/.hg/patches/
157 /star/webdir/b/
164 /star/webdir/b/
158 /star/webdir/c/
165 /star/webdir/c/
159 /star/webdir/notrepo/e/
166 /star/webdir/notrepo/e/
160 /star/webdir/notrepo/f/
167 /star/webdir/notrepo/f/
161 /starstar/webdir/a/
168 /starstar/webdir/a/
162 /starstar/webdir/a/.hg/patches/
169 /starstar/webdir/a/.hg/patches/
163 /starstar/webdir/b/
170 /starstar/webdir/b/
164 /starstar/webdir/b/d/
171 /starstar/webdir/b/d/
165 /starstar/webdir/c/
172 /starstar/webdir/c/
166 /starstar/webdir/notrepo/e/
173 /starstar/webdir/notrepo/e/
167 /starstar/webdir/notrepo/e/e2/
174 /starstar/webdir/notrepo/e/e2/
168 /starstar/webdir/notrepo/f/
175 /starstar/webdir/notrepo/f/
169 /starstar/webdir/notrepo/f/f2/
176 /starstar/webdir/notrepo/f/f2/
170 /astar/
177 /astar/
171 /astar/.hg/patches/
178 /astar/.hg/patches/
172
179
173 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=paper'
180 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=paper'
174 200 Script output follows
181 200 Script output follows
175
182
176 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
183 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
177 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
184 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
178 <head>
185 <head>
179 <link rel="icon" href="/static/hgicon.png" type="image/png" />
186 <link rel="icon" href="/static/hgicon.png" type="image/png" />
180 <meta name="robots" content="index, nofollow" />
187 <meta name="robots" content="index, nofollow" />
181 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
188 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
182 <script type="text/javascript" src="/static/mercurial.js"></script>
189 <script type="text/javascript" src="/static/mercurial.js"></script>
183
190
184 <title>Mercurial repositories index</title>
191 <title>Mercurial repositories index</title>
185 </head>
192 </head>
186 <body>
193 <body>
187
194
188 <div class="container">
195 <div class="container">
189 <div class="menu">
196 <div class="menu">
190 <a href="http://mercurial.selenic.com/">
197 <a href="http://mercurial.selenic.com/">
191 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
198 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
192 </div>
199 </div>
193 <div class="main">
200 <div class="main">
194 <h2>Mercurial Repositories</h2>
201 <h2>Mercurial Repositories</h2>
195
202
196 <table class="bigtable">
203 <table class="bigtable">
197 <tr>
204 <tr>
198 <th><a href="?sort=name">Name</a></th>
205 <th><a href="?sort=name">Name</a></th>
199 <th><a href="?sort=description">Description</a></th>
206 <th><a href="?sort=description">Description</a></th>
200 <th><a href="?sort=contact">Contact</a></th>
207 <th><a href="?sort=contact">Contact</a></th>
201 <th><a href="?sort=lastchange">Last modified</a></th>
208 <th><a href="?sort=lastchange">Last modified</a></th>
202 <th>&nbsp;</th>
209 <th>&nbsp;</th>
203 </tr>
210 </tr>
204
211
205 <tr class="parity0">
212 <tr class="parity0">
206 <td><a href="/t/a/?style=paper">t/a</a></td>
213 <td><a href="/t/a/?style=paper">t/a</a></td>
207 <td>unknown</td>
214 <td>unknown</td>
208 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
215 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
209 <td class="age">*</td> (glob)
216 <td class="age">*</td> (glob)
210 <td class="indexlinks"></td>
217 <td class="indexlinks"></td>
211 </tr>
218 </tr>
212
219
213 <tr class="parity1">
220 <tr class="parity1">
214 <td><a href="/b/?style=paper">b</a></td>
221 <td><a href="/b/?style=paper">b</a></td>
215 <td>unknown</td>
222 <td>unknown</td>
216 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
223 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
217 <td class="age">*</td> (glob)
224 <td class="age">*</td> (glob)
218 <td class="indexlinks"></td>
225 <td class="indexlinks"></td>
219 </tr>
226 </tr>
220
227
221 <tr class="parity0">
228 <tr class="parity0">
222 <td><a href="/coll/a/?style=paper">coll/a</a></td>
229 <td><a href="/coll/a/?style=paper">coll/a</a></td>
223 <td>unknown</td>
230 <td>unknown</td>
224 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
231 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
225 <td class="age">*</td> (glob)
232 <td class="age">*</td> (glob)
226 <td class="indexlinks"></td>
233 <td class="indexlinks"></td>
227 </tr>
234 </tr>
228
235
229 <tr class="parity1">
236 <tr class="parity1">
230 <td><a href="/coll/a/.hg/patches/?style=paper">coll/a/.hg/patches</a></td>
237 <td><a href="/coll/a/.hg/patches/?style=paper">coll/a/.hg/patches</a></td>
231 <td>unknown</td>
238 <td>unknown</td>
232 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
239 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
233 <td class="age">*</td> (glob)
240 <td class="age">*</td> (glob)
234 <td class="indexlinks"></td>
241 <td class="indexlinks"></td>
235 </tr>
242 </tr>
236
243
237 <tr class="parity0">
244 <tr class="parity0">
238 <td><a href="/coll/b/?style=paper">coll/b</a></td>
245 <td><a href="/coll/b/?style=paper">coll/b</a></td>
239 <td>unknown</td>
246 <td>unknown</td>
240 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
247 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
241 <td class="age">*</td> (glob)
248 <td class="age">*</td> (glob)
242 <td class="indexlinks"></td>
249 <td class="indexlinks"></td>
243 </tr>
250 </tr>
244
251
245 <tr class="parity1">
252 <tr class="parity1">
246 <td><a href="/coll/c/?style=paper">coll/c</a></td>
253 <td><a href="/coll/c/?style=paper">coll/c</a></td>
247 <td>unknown</td>
254 <td>unknown</td>
248 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
255 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
249 <td class="age">*</td> (glob)
256 <td class="age">*</td> (glob)
250 <td class="indexlinks"></td>
257 <td class="indexlinks"></td>
251 </tr>
258 </tr>
252
259
253 <tr class="parity0">
260 <tr class="parity0">
254 <td><a href="/coll/notrepo/e/?style=paper">coll/notrepo/e</a></td>
261 <td><a href="/coll/notrepo/e/?style=paper">coll/notrepo/e</a></td>
255 <td>unknown</td>
262 <td>unknown</td>
256 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
263 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
257 <td class="age">*</td> (glob)
264 <td class="age">*</td> (glob)
258 <td class="indexlinks"></td>
265 <td class="indexlinks"></td>
259 </tr>
266 </tr>
260
267
261 <tr class="parity1">
268 <tr class="parity1">
262 <td><a href="/coll/notrepo/f/?style=paper">coll/notrepo/f</a></td>
269 <td><a href="/coll/notrepo/f/?style=paper">coll/notrepo/f</a></td>
263 <td>unknown</td>
270 <td>unknown</td>
264 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
271 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
265 <td class="age">*</td> (glob)
272 <td class="age">*</td> (glob)
266 <td class="indexlinks"></td>
273 <td class="indexlinks"></td>
267 </tr>
274 </tr>
268
275
269 <tr class="parity0">
276 <tr class="parity0">
270 <td><a href="/rcoll/a/?style=paper">rcoll/a</a></td>
277 <td><a href="/rcoll/a/?style=paper">rcoll/a</a></td>
271 <td>unknown</td>
278 <td>unknown</td>
272 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
279 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
273 <td class="age">*</td> (glob)
280 <td class="age">*</td> (glob)
274 <td class="indexlinks"></td>
281 <td class="indexlinks"></td>
275 </tr>
282 </tr>
276
283
277 <tr class="parity1">
284 <tr class="parity1">
278 <td><a href="/rcoll/a/.hg/patches/?style=paper">rcoll/a/.hg/patches</a></td>
285 <td><a href="/rcoll/a/.hg/patches/?style=paper">rcoll/a/.hg/patches</a></td>
279 <td>unknown</td>
286 <td>unknown</td>
280 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
287 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
281 <td class="age">*</td> (glob)
288 <td class="age">*</td> (glob)
282 <td class="indexlinks"></td>
289 <td class="indexlinks"></td>
283 </tr>
290 </tr>
284
291
285 <tr class="parity0">
292 <tr class="parity0">
286 <td><a href="/rcoll/b/?style=paper">rcoll/b</a></td>
293 <td><a href="/rcoll/b/?style=paper">rcoll/b</a></td>
287 <td>unknown</td>
294 <td>unknown</td>
288 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
295 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
289 <td class="age">*</td> (glob)
296 <td class="age">*</td> (glob)
290 <td class="indexlinks"></td>
297 <td class="indexlinks"></td>
291 </tr>
298 </tr>
292
299
293 <tr class="parity1">
300 <tr class="parity1">
294 <td><a href="/rcoll/b/d/?style=paper">rcoll/b/d</a></td>
301 <td><a href="/rcoll/b/d/?style=paper">rcoll/b/d</a></td>
295 <td>unknown</td>
302 <td>unknown</td>
296 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
303 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
297 <td class="age">*</td> (glob)
304 <td class="age">*</td> (glob)
298 <td class="indexlinks"></td>
305 <td class="indexlinks"></td>
299 </tr>
306 </tr>
300
307
301 <tr class="parity0">
308 <tr class="parity0">
302 <td><a href="/rcoll/c/?style=paper">rcoll/c</a></td>
309 <td><a href="/rcoll/c/?style=paper">rcoll/c</a></td>
303 <td>unknown</td>
310 <td>unknown</td>
304 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
311 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
305 <td class="age">*</td> (glob)
312 <td class="age">*</td> (glob)
306 <td class="indexlinks"></td>
313 <td class="indexlinks"></td>
307 </tr>
314 </tr>
308
315
309 <tr class="parity1">
316 <tr class="parity1">
310 <td><a href="/rcoll/notrepo/e/?style=paper">rcoll/notrepo/e</a></td>
317 <td><a href="/rcoll/notrepo/e/?style=paper">rcoll/notrepo/e</a></td>
311 <td>unknown</td>
318 <td>unknown</td>
312 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
319 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
313 <td class="age">*</td> (glob)
320 <td class="age">*</td> (glob)
314 <td class="indexlinks"></td>
321 <td class="indexlinks"></td>
315 </tr>
322 </tr>
316
323
317 <tr class="parity0">
324 <tr class="parity0">
318 <td><a href="/rcoll/notrepo/e/e2/?style=paper">rcoll/notrepo/e/e2</a></td>
325 <td><a href="/rcoll/notrepo/e/e2/?style=paper">rcoll/notrepo/e/e2</a></td>
319 <td>unknown</td>
326 <td>unknown</td>
320 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
327 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
321 <td class="age">*</td> (glob)
328 <td class="age">*</td> (glob)
322 <td class="indexlinks"></td>
329 <td class="indexlinks"></td>
323 </tr>
330 </tr>
324
331
325 <tr class="parity1">
332 <tr class="parity1">
326 <td><a href="/rcoll/notrepo/f/?style=paper">rcoll/notrepo/f</a></td>
333 <td><a href="/rcoll/notrepo/f/?style=paper">rcoll/notrepo/f</a></td>
327 <td>unknown</td>
334 <td>unknown</td>
328 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
335 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
329 <td class="age">*</td> (glob)
336 <td class="age">*</td> (glob)
330 <td class="indexlinks"></td>
337 <td class="indexlinks"></td>
331 </tr>
338 </tr>
332
339
333 <tr class="parity0">
340 <tr class="parity0">
334 <td><a href="/rcoll/notrepo/f/f2/?style=paper">rcoll/notrepo/f/f2</a></td>
341 <td><a href="/rcoll/notrepo/f/f2/?style=paper">rcoll/notrepo/f/f2</a></td>
335 <td>unknown</td>
342 <td>unknown</td>
336 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
343 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
337 <td class="age">*</td> (glob)
344 <td class="age">*</td> (glob)
338 <td class="indexlinks"></td>
345 <td class="indexlinks"></td>
339 </tr>
346 </tr>
340
347
341 <tr class="parity1">
348 <tr class="parity1">
342 <td><a href="/star/webdir/a/?style=paper">star/webdir/a</a></td>
349 <td><a href="/star/webdir/a/?style=paper">star/webdir/a</a></td>
343 <td>unknown</td>
350 <td>unknown</td>
344 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
351 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
345 <td class="age">*</td> (glob)
352 <td class="age">*</td> (glob)
346 <td class="indexlinks"></td>
353 <td class="indexlinks"></td>
347 </tr>
354 </tr>
348
355
349 <tr class="parity0">
356 <tr class="parity0">
350 <td><a href="/star/webdir/a/.hg/patches/?style=paper">star/webdir/a/.hg/patches</a></td>
357 <td><a href="/star/webdir/a/.hg/patches/?style=paper">star/webdir/a/.hg/patches</a></td>
351 <td>unknown</td>
358 <td>unknown</td>
352 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
359 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
353 <td class="age">*</td> (glob)
360 <td class="age">*</td> (glob)
354 <td class="indexlinks"></td>
361 <td class="indexlinks"></td>
355 </tr>
362 </tr>
356
363
357 <tr class="parity1">
364 <tr class="parity1">
358 <td><a href="/star/webdir/b/?style=paper">star/webdir/b</a></td>
365 <td><a href="/star/webdir/b/?style=paper">star/webdir/b</a></td>
359 <td>unknown</td>
366 <td>unknown</td>
360 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
367 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
361 <td class="age">*</td> (glob)
368 <td class="age">*</td> (glob)
362 <td class="indexlinks"></td>
369 <td class="indexlinks"></td>
363 </tr>
370 </tr>
364
371
365 <tr class="parity0">
372 <tr class="parity0">
366 <td><a href="/star/webdir/c/?style=paper">star/webdir/c</a></td>
373 <td><a href="/star/webdir/c/?style=paper">star/webdir/c</a></td>
367 <td>unknown</td>
374 <td>unknown</td>
368 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
375 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
369 <td class="age">*</td> (glob)
376 <td class="age">*</td> (glob)
370 <td class="indexlinks"></td>
377 <td class="indexlinks"></td>
371 </tr>
378 </tr>
372
379
373 <tr class="parity1">
380 <tr class="parity1">
374 <td><a href="/star/webdir/notrepo/e/?style=paper">star/webdir/notrepo/e</a></td>
381 <td><a href="/star/webdir/notrepo/e/?style=paper">star/webdir/notrepo/e</a></td>
375 <td>unknown</td>
382 <td>unknown</td>
376 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
383 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
377 <td class="age">*</td> (glob)
384 <td class="age">*</td> (glob)
378 <td class="indexlinks"></td>
385 <td class="indexlinks"></td>
379 </tr>
386 </tr>
380
387
381 <tr class="parity0">
388 <tr class="parity0">
382 <td><a href="/star/webdir/notrepo/f/?style=paper">star/webdir/notrepo/f</a></td>
389 <td><a href="/star/webdir/notrepo/f/?style=paper">star/webdir/notrepo/f</a></td>
383 <td>unknown</td>
390 <td>unknown</td>
384 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
391 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
385 <td class="age">*</td> (glob)
392 <td class="age">*</td> (glob)
386 <td class="indexlinks"></td>
393 <td class="indexlinks"></td>
387 </tr>
394 </tr>
388
395
389 <tr class="parity1">
396 <tr class="parity1">
390 <td><a href="/starstar/webdir/a/?style=paper">starstar/webdir/a</a></td>
397 <td><a href="/starstar/webdir/a/?style=paper">starstar/webdir/a</a></td>
391 <td>unknown</td>
398 <td>unknown</td>
392 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
399 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
393 <td class="age">*</td> (glob)
400 <td class="age">*</td> (glob)
394 <td class="indexlinks"></td>
401 <td class="indexlinks"></td>
395 </tr>
402 </tr>
396
403
397 <tr class="parity0">
404 <tr class="parity0">
398 <td><a href="/starstar/webdir/a/.hg/patches/?style=paper">starstar/webdir/a/.hg/patches</a></td>
405 <td><a href="/starstar/webdir/a/.hg/patches/?style=paper">starstar/webdir/a/.hg/patches</a></td>
399 <td>unknown</td>
406 <td>unknown</td>
400 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
407 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
401 <td class="age">*</td> (glob)
408 <td class="age">*</td> (glob)
402 <td class="indexlinks"></td>
409 <td class="indexlinks"></td>
403 </tr>
410 </tr>
404
411
405 <tr class="parity1">
412 <tr class="parity1">
406 <td><a href="/starstar/webdir/b/?style=paper">starstar/webdir/b</a></td>
413 <td><a href="/starstar/webdir/b/?style=paper">starstar/webdir/b</a></td>
407 <td>unknown</td>
414 <td>unknown</td>
408 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
415 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
409 <td class="age">*</td> (glob)
416 <td class="age">*</td> (glob)
410 <td class="indexlinks"></td>
417 <td class="indexlinks"></td>
411 </tr>
418 </tr>
412
419
413 <tr class="parity0">
420 <tr class="parity0">
414 <td><a href="/starstar/webdir/b/d/?style=paper">starstar/webdir/b/d</a></td>
421 <td><a href="/starstar/webdir/b/d/?style=paper">starstar/webdir/b/d</a></td>
415 <td>unknown</td>
422 <td>unknown</td>
416 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
423 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
417 <td class="age">*</td> (glob)
424 <td class="age">*</td> (glob)
418 <td class="indexlinks"></td>
425 <td class="indexlinks"></td>
419 </tr>
426 </tr>
420
427
421 <tr class="parity1">
428 <tr class="parity1">
422 <td><a href="/starstar/webdir/c/?style=paper">starstar/webdir/c</a></td>
429 <td><a href="/starstar/webdir/c/?style=paper">starstar/webdir/c</a></td>
423 <td>unknown</td>
430 <td>unknown</td>
424 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
431 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
425 <td class="age">*</td> (glob)
432 <td class="age">*</td> (glob)
426 <td class="indexlinks"></td>
433 <td class="indexlinks"></td>
427 </tr>
434 </tr>
428
435
429 <tr class="parity0">
436 <tr class="parity0">
430 <td><a href="/starstar/webdir/notrepo/e/?style=paper">starstar/webdir/notrepo/e</a></td>
437 <td><a href="/starstar/webdir/notrepo/e/?style=paper">starstar/webdir/notrepo/e</a></td>
431 <td>unknown</td>
438 <td>unknown</td>
432 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
439 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
433 <td class="age">*</td> (glob)
440 <td class="age">*</td> (glob)
434 <td class="indexlinks"></td>
441 <td class="indexlinks"></td>
435 </tr>
442 </tr>
436
443
437 <tr class="parity1">
444 <tr class="parity1">
438 <td><a href="/starstar/webdir/notrepo/e/e2/?style=paper">starstar/webdir/notrepo/e/e2</a></td>
445 <td><a href="/starstar/webdir/notrepo/e/e2/?style=paper">starstar/webdir/notrepo/e/e2</a></td>
439 <td>unknown</td>
446 <td>unknown</td>
440 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
447 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
441 <td class="age">*</td> (glob)
448 <td class="age">*</td> (glob)
442 <td class="indexlinks"></td>
449 <td class="indexlinks"></td>
443 </tr>
450 </tr>
444
451
445 <tr class="parity0">
452 <tr class="parity0">
446 <td><a href="/starstar/webdir/notrepo/f/?style=paper">starstar/webdir/notrepo/f</a></td>
453 <td><a href="/starstar/webdir/notrepo/f/?style=paper">starstar/webdir/notrepo/f</a></td>
447 <td>unknown</td>
454 <td>unknown</td>
448 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
455 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
449 <td class="age">*</td> (glob)
456 <td class="age">*</td> (glob)
450 <td class="indexlinks"></td>
457 <td class="indexlinks"></td>
451 </tr>
458 </tr>
452
459
453 <tr class="parity1">
460 <tr class="parity1">
454 <td><a href="/starstar/webdir/notrepo/f/f2/?style=paper">starstar/webdir/notrepo/f/f2</a></td>
461 <td><a href="/starstar/webdir/notrepo/f/f2/?style=paper">starstar/webdir/notrepo/f/f2</a></td>
455 <td>unknown</td>
462 <td>unknown</td>
456 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
463 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
457 <td class="age">*</td> (glob)
464 <td class="age">*</td> (glob)
458 <td class="indexlinks"></td>
465 <td class="indexlinks"></td>
459 </tr>
466 </tr>
460
467
461 <tr class="parity0">
468 <tr class="parity0">
462 <td><a href="/astar/?style=paper">astar</a></td>
469 <td><a href="/astar/?style=paper">astar</a></td>
463 <td>unknown</td>
470 <td>unknown</td>
464 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
471 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
465 <td class="age">*</td> (glob)
472 <td class="age">*</td> (glob)
466 <td class="indexlinks"></td>
473 <td class="indexlinks"></td>
467 </tr>
474 </tr>
468
475
469 <tr class="parity1">
476 <tr class="parity1">
470 <td><a href="/astar/.hg/patches/?style=paper">astar/.hg/patches</a></td>
477 <td><a href="/astar/.hg/patches/?style=paper">astar/.hg/patches</a></td>
471 <td>unknown</td>
478 <td>unknown</td>
472 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
479 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
473 <td class="age">*</td> (glob)
480 <td class="age">*</td> (glob)
474 <td class="indexlinks"></td>
481 <td class="indexlinks"></td>
475 </tr>
482 </tr>
476
483
477 </table>
484 </table>
478 </div>
485 </div>
479 </div>
486 </div>
480 <script type="text/javascript">process_dates()</script>
487 <script type="text/javascript">process_dates()</script>
481
488
482
489
483 </body>
490 </body>
484 </html>
491 </html>
485
492
486 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t?style=raw'
493 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t?style=raw'
487 200 Script output follows
494 200 Script output follows
488
495
489
496
490 /t/a/
497 /t/a/
491
498
492 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
499 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
493 200 Script output follows
500 200 Script output follows
494
501
495
502
496 /t/a/
503 /t/a/
497
504
498 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=paper'
505 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=paper'
499 200 Script output follows
506 200 Script output follows
500
507
501 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
508 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
502 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
509 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
503 <head>
510 <head>
504 <link rel="icon" href="/static/hgicon.png" type="image/png" />
511 <link rel="icon" href="/static/hgicon.png" type="image/png" />
505 <meta name="robots" content="index, nofollow" />
512 <meta name="robots" content="index, nofollow" />
506 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
513 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
507 <script type="text/javascript" src="/static/mercurial.js"></script>
514 <script type="text/javascript" src="/static/mercurial.js"></script>
508
515
509 <title>Mercurial repositories index</title>
516 <title>Mercurial repositories index</title>
510 </head>
517 </head>
511 <body>
518 <body>
512
519
513 <div class="container">
520 <div class="container">
514 <div class="menu">
521 <div class="menu">
515 <a href="http://mercurial.selenic.com/">
522 <a href="http://mercurial.selenic.com/">
516 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
523 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
517 </div>
524 </div>
518 <div class="main">
525 <div class="main">
519 <h2>Mercurial Repositories</h2>
526 <h2>Mercurial Repositories</h2>
520
527
521 <table class="bigtable">
528 <table class="bigtable">
522 <tr>
529 <tr>
523 <th><a href="?sort=name">Name</a></th>
530 <th><a href="?sort=name">Name</a></th>
524 <th><a href="?sort=description">Description</a></th>
531 <th><a href="?sort=description">Description</a></th>
525 <th><a href="?sort=contact">Contact</a></th>
532 <th><a href="?sort=contact">Contact</a></th>
526 <th><a href="?sort=lastchange">Last modified</a></th>
533 <th><a href="?sort=lastchange">Last modified</a></th>
527 <th>&nbsp;</th>
534 <th>&nbsp;</th>
528 </tr>
535 </tr>
529
536
530 <tr class="parity0">
537 <tr class="parity0">
531 <td><a href="/t/a/?style=paper">a</a></td>
538 <td><a href="/t/a/?style=paper">a</a></td>
532 <td>unknown</td>
539 <td>unknown</td>
533 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
540 <td>&#70;&#111;&#111;&#32;&#66;&#97;&#114;&#32;&#60;&#102;&#111;&#111;&#46;&#98;&#97;&#114;&#64;&#101;&#120;&#97;&#109;&#112;&#108;&#101;&#46;&#99;&#111;&#109;&#62;</td>
534 <td class="age">*</td> (glob)
541 <td class="age">*</td> (glob)
535 <td class="indexlinks"></td>
542 <td class="indexlinks"></td>
536 </tr>
543 </tr>
537
544
538 </table>
545 </table>
539 </div>
546 </div>
540 </div>
547 </div>
541 <script type="text/javascript">process_dates()</script>
548 <script type="text/javascript">process_dates()</script>
542
549
543
550
544 </body>
551 </body>
545 </html>
552 </html>
546
553
547 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/a?style=atom'
554 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/a?style=atom'
548 200 Script output follows
555 200 Script output follows
549
556
550 <?xml version="1.0" encoding="ascii"?>
557 <?xml version="1.0" encoding="ascii"?>
551 <feed xmlns="http://www.w3.org/2005/Atom">
558 <feed xmlns="http://www.w3.org/2005/Atom">
552 <!-- Changelog -->
559 <!-- Changelog -->
553 <id>http://*:$HGPORT1/t/a/</id> (glob)
560 <id>http://*:$HGPORT1/t/a/</id> (glob)
554 <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob)
561 <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob)
555 <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob)
562 <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob)
556 <title>t/a Changelog</title>
563 <title>t/a Changelog</title>
557 <updated>1970-01-01T00:00:01+00:00</updated>
564 <updated>1970-01-01T00:00:01+00:00</updated>
558
565
559 <entry>
566 <entry>
560 <title>a</title>
567 <title>a</title>
561 <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob)
568 <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob)
562 <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob)
569 <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob)
563 <author>
570 <author>
564 <name>test</name>
571 <name>test</name>
565 <email>&#116;&#101;&#115;&#116;</email>
572 <email>&#116;&#101;&#115;&#116;</email>
566 </author>
573 </author>
567 <updated>1970-01-01T00:00:01+00:00</updated>
574 <updated>1970-01-01T00:00:01+00:00</updated>
568 <published>1970-01-01T00:00:01+00:00</published>
575 <published>1970-01-01T00:00:01+00:00</published>
569 <content type="xhtml">
576 <content type="xhtml">
570 <div xmlns="http://www.w3.org/1999/xhtml">
577 <div xmlns="http://www.w3.org/1999/xhtml">
571 <pre xml:space="preserve">a</pre>
578 <pre xml:space="preserve">a</pre>
572 </div>
579 </div>
573 </content>
580 </content>
574 </entry>
581 </entry>
575
582
576 </feed>
583 </feed>
577 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/a/?style=atom'
584 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/a/?style=atom'
578 200 Script output follows
585 200 Script output follows
579
586
580 <?xml version="1.0" encoding="ascii"?>
587 <?xml version="1.0" encoding="ascii"?>
581 <feed xmlns="http://www.w3.org/2005/Atom">
588 <feed xmlns="http://www.w3.org/2005/Atom">
582 <!-- Changelog -->
589 <!-- Changelog -->
583 <id>http://*:$HGPORT1/t/a/</id> (glob)
590 <id>http://*:$HGPORT1/t/a/</id> (glob)
584 <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob)
591 <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob)
585 <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob)
592 <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob)
586 <title>t/a Changelog</title>
593 <title>t/a Changelog</title>
587 <updated>1970-01-01T00:00:01+00:00</updated>
594 <updated>1970-01-01T00:00:01+00:00</updated>
588
595
589 <entry>
596 <entry>
590 <title>a</title>
597 <title>a</title>
591 <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob)
598 <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob)
592 <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob)
599 <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob)
593 <author>
600 <author>
594 <name>test</name>
601 <name>test</name>
595 <email>&#116;&#101;&#115;&#116;</email>
602 <email>&#116;&#101;&#115;&#116;</email>
596 </author>
603 </author>
597 <updated>1970-01-01T00:00:01+00:00</updated>
604 <updated>1970-01-01T00:00:01+00:00</updated>
598 <published>1970-01-01T00:00:01+00:00</published>
605 <published>1970-01-01T00:00:01+00:00</published>
599 <content type="xhtml">
606 <content type="xhtml">
600 <div xmlns="http://www.w3.org/1999/xhtml">
607 <div xmlns="http://www.w3.org/1999/xhtml">
601 <pre xml:space="preserve">a</pre>
608 <pre xml:space="preserve">a</pre>
602 </div>
609 </div>
603 </content>
610 </content>
604 </entry>
611 </entry>
605
612
606 </feed>
613 </feed>
607 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/a/file/tip/a?style=raw'
614 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/a/file/tip/a?style=raw'
608 200 Script output follows
615 200 Script output follows
609
616
610 a
617 a
611
618
612 Test [paths] '*' extension
619 Test [paths] '*' extension
613
620
614 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/?style=raw'
621 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/?style=raw'
615 200 Script output follows
622 200 Script output follows
616
623
617
624
618 /coll/a/
625 /coll/a/
619 /coll/a/.hg/patches/
626 /coll/a/.hg/patches/
620 /coll/b/
627 /coll/b/
621 /coll/c/
628 /coll/c/
622 /coll/notrepo/e/
629 /coll/notrepo/e/
623 /coll/notrepo/f/
630 /coll/notrepo/f/
624
631
625 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/a/file/tip/a?style=raw'
632 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/a/file/tip/a?style=raw'
626 200 Script output follows
633 200 Script output follows
627
634
628 a
635 a
629
636
630 Test [paths] '**' extension
637 Test [paths] '**' extension
631
638
632 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/?style=raw'
639 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/?style=raw'
633 200 Script output follows
640 200 Script output follows
634
641
635
642
636 /rcoll/a/
643 /rcoll/a/
637 /rcoll/a/.hg/patches/
644 /rcoll/a/.hg/patches/
638 /rcoll/b/
645 /rcoll/b/
639 /rcoll/b/d/
646 /rcoll/b/d/
640 /rcoll/c/
647 /rcoll/c/
641 /rcoll/notrepo/e/
648 /rcoll/notrepo/e/
642 /rcoll/notrepo/e/e2/
649 /rcoll/notrepo/e/e2/
643 /rcoll/notrepo/f/
650 /rcoll/notrepo/f/
644 /rcoll/notrepo/f/f2/
651 /rcoll/notrepo/f/f2/
645
652
646 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/b/d/file/tip/d?style=raw'
653 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/b/d/file/tip/d?style=raw'
647 200 Script output follows
654 200 Script output follows
648
655
649 d
656 d
650
657
651 Test collapse = True
658 Test collapse = True
652
659
653 $ "$TESTDIR/killdaemons.py"
660 $ "$TESTDIR/killdaemons.py"
654 $ cat >> paths.conf <<EOF
661 $ cat >> paths.conf <<EOF
655 > [web]
662 > [web]
656 > collapse=true
663 > collapse=true
657 > EOF
664 > EOF
658 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
665 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
659 > -A access-paths.log -E error-paths-3.log
666 > -A access-paths.log -E error-paths-3.log
660 $ cat hg.pid >> $DAEMON_PIDS
667 $ cat hg.pid >> $DAEMON_PIDS
661 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/?style=raw'
668 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/?style=raw'
662 200 Script output follows
669 200 Script output follows
663
670
664
671
665 /coll/a/
672 /coll/a/
666 /coll/a/.hg/patches/
673 /coll/a/.hg/patches/
667 /coll/b/
674 /coll/b/
668 /coll/c/
675 /coll/c/
669 /coll/notrepo/
676 /coll/notrepo/
670
677
671 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/a/file/tip/a?style=raw'
678 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/a/file/tip/a?style=raw'
672 200 Script output follows
679 200 Script output follows
673
680
674 a
681 a
675 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/?style=raw'
682 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/?style=raw'
676 200 Script output follows
683 200 Script output follows
677
684
678
685
679 /rcoll/a/
686 /rcoll/a/
680 /rcoll/a/.hg/patches/
687 /rcoll/a/.hg/patches/
681 /rcoll/b/
688 /rcoll/b/
682 /rcoll/b/d/
689 /rcoll/b/d/
683 /rcoll/c/
690 /rcoll/c/
684 /rcoll/notrepo/
691 /rcoll/notrepo/
685
692
686 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/b/d/file/tip/d?style=raw'
693 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/b/d/file/tip/d?style=raw'
687 200 Script output follows
694 200 Script output follows
688
695
689 d
696 d
690
697
691 Test intermediate directories
698 Test intermediate directories
692
699
693 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/?style=raw'
700 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/?style=raw'
694 200 Script output follows
701 200 Script output follows
695
702
696
703
697 /rcoll/notrepo/e/
704 /rcoll/notrepo/e/
698 /rcoll/notrepo/e/e2/
705 /rcoll/notrepo/e/e2/
699 /rcoll/notrepo/f/
706 /rcoll/notrepo/f/
700 /rcoll/notrepo/f/f2/
707 /rcoll/notrepo/f/f2/
701
708
702
709
703 Test repositories inside intermediate directories
710 Test repositories inside intermediate directories
704
711
705 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/e/file/tip/e?style=raw'
712 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/e/file/tip/e?style=raw'
706 200 Script output follows
713 200 Script output follows
707
714
708 e
715 e
709
716
710 Test subrepositories inside intermediate directories
717 Test subrepositories inside intermediate directories
711
718
712 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/f/f2/file/tip/f2?style=raw'
719 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/f/f2/file/tip/f2?style=raw'
713 200 Script output follows
720 200 Script output follows
714
721
715 f2
722 f2
716
723
717 Test descend = False
724 Test descend = False
718
725
719 $ "$TESTDIR/killdaemons.py"
726 $ "$TESTDIR/killdaemons.py"
720 $ cat >> paths.conf <<EOF
727 $ cat >> paths.conf <<EOF
721 > descend=false
728 > descend=false
722 > EOF
729 > EOF
723 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
730 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
724 > -A access-paths.log -E error-paths-4.log
731 > -A access-paths.log -E error-paths-4.log
725 $ cat hg.pid >> $DAEMON_PIDS
732 $ cat hg.pid >> $DAEMON_PIDS
726 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/?style=raw'
733 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/?style=raw'
727 200 Script output follows
734 200 Script output follows
728
735
729
736
730 /coll/a/
737 /coll/a/
731 /coll/b/
738 /coll/b/
732 /coll/c/
739 /coll/c/
733
740
734 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/a/file/tip/a?style=raw'
741 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/coll/a/file/tip/a?style=raw'
735 200 Script output follows
742 200 Script output follows
736
743
737 a
744 a
738 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/?style=raw'
745 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/?style=raw'
739 200 Script output follows
746 200 Script output follows
740
747
741
748
742 /rcoll/a/
749 /rcoll/a/
743 /rcoll/b/
750 /rcoll/b/
744 /rcoll/c/
751 /rcoll/c/
745
752
746 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/b/d/file/tip/d?style=raw'
753 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/b/d/file/tip/d?style=raw'
747 200 Script output follows
754 200 Script output follows
748
755
749 d
756 d
750
757
751 Test intermediate directories
758 Test intermediate directories
752
759
753 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/?style=raw'
760 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/?style=raw'
754 200 Script output follows
761 200 Script output follows
755
762
756
763
757 /rcoll/notrepo/e/
764 /rcoll/notrepo/e/
758 /rcoll/notrepo/f/
765 /rcoll/notrepo/f/
759
766
760
767
761 Test repositories inside intermediate directories
768 Test repositories inside intermediate directories
762
769
763 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/e/file/tip/e?style=raw'
770 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/e/file/tip/e?style=raw'
764 200 Script output follows
771 200 Script output follows
765
772
766 e
773 e
767
774
768 Test subrepositories inside intermediate directories
775 Test subrepositories inside intermediate directories
769
776
770 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/f/f2/file/tip/f2?style=raw'
777 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/rcoll/notrepo/f/f2/file/tip/f2?style=raw'
771 200 Script output follows
778 200 Script output follows
772
779
773 f2
780 f2
774
781
775 Test [paths] '*' in a repo root
782 Test [paths] '*' in a repo root
776
783
777 $ hg id http://localhost:$HGPORT1/astar
784 $ hg id http://localhost:$HGPORT1/astar
778 8580ff50825a
785 8580ff50825a
779
786
780 $ "$TESTDIR/killdaemons.py"
787 $ "$TESTDIR/killdaemons.py"
781 $ cat > paths.conf <<EOF
788 $ cat > paths.conf <<EOF
782 > [paths]
789 > [paths]
783 > t/a = $root/a
790 > t/a = $root/a
784 > t/b = $root/b
791 > t/b = $root/b
785 > c = $root/c
792 > c = $root/c
786 > EOF
793 > EOF
787 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
794 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
788 > -A access-paths.log -E error-paths-5.log
795 > -A access-paths.log -E error-paths-5.log
789 $ cat hg.pid >> $DAEMON_PIDS
796 $ cat hg.pid >> $DAEMON_PIDS
790 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
797 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
791 200 Script output follows
798 200 Script output follows
792
799
793
800
794 /t/a/
801 /t/a/
795 /t/b/
802 /t/b/
796 /c/
803 /c/
797
804
798 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
805 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
799 200 Script output follows
806 200 Script output follows
800
807
801
808
802 /t/a/
809 /t/a/
803 /t/b/
810 /t/b/
804
811
805
812
806 Test collapse = True
813 Test collapse = True
807
814
808 $ "$TESTDIR/killdaemons.py"
815 $ "$TESTDIR/killdaemons.py"
809 $ cat >> paths.conf <<EOF
816 $ cat >> paths.conf <<EOF
810 > [web]
817 > [web]
811 > collapse=true
818 > collapse=true
812 > EOF
819 > EOF
813 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
820 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
814 > -A access-paths.log -E error-paths-6.log
821 > -A access-paths.log -E error-paths-6.log
815 $ cat hg.pid >> $DAEMON_PIDS
822 $ cat hg.pid >> $DAEMON_PIDS
816 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
823 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
817 200 Script output follows
824 200 Script output follows
818
825
819
826
820 /t/
827 /t/
821 /c/
828 /c/
822
829
823 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
830 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
824 200 Script output follows
831 200 Script output follows
825
832
826
833
827 /t/a/
834 /t/a/
828 /t/b/
835 /t/b/
829
836
830
837
831 test descend = False
838 test descend = False
832
839
833 $ "$TESTDIR/killdaemons.py"
840 $ "$TESTDIR/killdaemons.py"
834 $ cat >> paths.conf <<EOF
841 $ cat >> paths.conf <<EOF
835 > descend=false
842 > descend=false
836 > EOF
843 > EOF
837 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
844 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
838 > -A access-paths.log -E error-paths-7.log
845 > -A access-paths.log -E error-paths-7.log
839 $ cat hg.pid >> $DAEMON_PIDS
846 $ cat hg.pid >> $DAEMON_PIDS
840 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
847 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
841 200 Script output follows
848 200 Script output follows
842
849
843
850
844 /c/
851 /c/
845
852
846 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
853 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/t/?style=raw'
847 200 Script output follows
854 200 Script output follows
848
855
849
856
850 /t/a/
857 /t/a/
851 /t/b/
858 /t/b/
852
859
853 $ "$TESTDIR/killdaemons.py"
860 $ "$TESTDIR/killdaemons.py"
854 $ cat > paths.conf <<EOF
861 $ cat > paths.conf <<EOF
855 > [paths]
862 > [paths]
856 > nostore = $root/nostore
863 > nostore = $root/nostore
857 > inexistent = $root/inexistent
864 > inexistent = $root/inexistent
858 > EOF
865 > EOF
859 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
866 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \
860 > -A access-paths.log -E error-paths-8.log
867 > -A access-paths.log -E error-paths-8.log
861 $ cat hg.pid >> $DAEMON_PIDS
868 $ cat hg.pid >> $DAEMON_PIDS
862
869
863 test inexistent and inaccessible repo should be ignored silently
870 test inexistent and inaccessible repo should be ignored silently
864
871
865 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/'
872 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/'
866 200 Script output follows
873 200 Script output follows
867
874
868 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
875 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
869 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
876 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">
870 <head>
877 <head>
871 <link rel="icon" href="/static/hgicon.png" type="image/png" />
878 <link rel="icon" href="/static/hgicon.png" type="image/png" />
872 <meta name="robots" content="index, nofollow" />
879 <meta name="robots" content="index, nofollow" />
873 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
880 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" />
874 <script type="text/javascript" src="/static/mercurial.js"></script>
881 <script type="text/javascript" src="/static/mercurial.js"></script>
875
882
876 <title>Mercurial repositories index</title>
883 <title>Mercurial repositories index</title>
877 </head>
884 </head>
878 <body>
885 <body>
879
886
880 <div class="container">
887 <div class="container">
881 <div class="menu">
888 <div class="menu">
882 <a href="http://mercurial.selenic.com/">
889 <a href="http://mercurial.selenic.com/">
883 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
890 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a>
884 </div>
891 </div>
885 <div class="main">
892 <div class="main">
886 <h2>Mercurial Repositories</h2>
893 <h2>Mercurial Repositories</h2>
887
894
888 <table class="bigtable">
895 <table class="bigtable">
889 <tr>
896 <tr>
890 <th><a href="?sort=name">Name</a></th>
897 <th><a href="?sort=name">Name</a></th>
891 <th><a href="?sort=description">Description</a></th>
898 <th><a href="?sort=description">Description</a></th>
892 <th><a href="?sort=contact">Contact</a></th>
899 <th><a href="?sort=contact">Contact</a></th>
893 <th><a href="?sort=lastchange">Last modified</a></th>
900 <th><a href="?sort=lastchange">Last modified</a></th>
894 <th>&nbsp;</th>
901 <th>&nbsp;</th>
895 </tr>
902 </tr>
896
903
897 </table>
904 </table>
898 </div>
905 </div>
899 </div>
906 </div>
900 <script type="text/javascript">process_dates()</script>
907 <script type="text/javascript">process_dates()</script>
901
908
902
909
903 </body>
910 </body>
904 </html>
911 </html>
905
912
906 $ cat > collections.conf <<EOF
913 $ cat > collections.conf <<EOF
907 > [collections]
914 > [collections]
908 > $root=$root
915 > $root=$root
909 > EOF
916 > EOF
910 $ hg serve --config web.baseurl=http://hg.example.com:8080/ -p $HGPORT2 -d \
917 $ hg serve --config web.baseurl=http://hg.example.com:8080/ -p $HGPORT2 -d \
911 > --pid-file=hg.pid --webdir-conf collections.conf \
918 > --pid-file=hg.pid --webdir-conf collections.conf \
912 > -A access-collections.log -E error-collections.log
919 > -A access-collections.log -E error-collections.log
913 $ cat hg.pid >> $DAEMON_PIDS
920 $ cat hg.pid >> $DAEMON_PIDS
914
921
915 collections: should succeed
922 collections: should succeed
916
923
917 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/?style=raw'
924 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/?style=raw'
918 200 Script output follows
925 200 Script output follows
919
926
920
927
921 /a/
928 /a/
922 /a/.hg/patches/
929 /a/.hg/patches/
923 /b/
930 /b/
924 /c/
931 /c/
925 /notrepo/e/
932 /notrepo/e/
926 /notrepo/f/
933 /notrepo/f/
927
934
928 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/file/tip/a?style=raw'
935 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/file/tip/a?style=raw'
929 200 Script output follows
936 200 Script output follows
930
937
931 a
938 a
932 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/b/file/tip/b?style=raw'
939 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/b/file/tip/b?style=raw'
933 200 Script output follows
940 200 Script output follows
934
941
935 b
942 b
936 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/c/file/tip/c?style=raw'
943 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/c/file/tip/c?style=raw'
937 200 Script output follows
944 200 Script output follows
938
945
939 c
946 c
940
947
941 atom-log with basedir /
948 atom-log with basedir /
942
949
943 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/atom-log' | grep '<link'
950 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/atom-log' | grep '<link'
944 <link rel="self" href="http://hg.example.com:8080/a/atom-log"/>
951 <link rel="self" href="http://hg.example.com:8080/a/atom-log"/>
945 <link rel="alternate" href="http://hg.example.com:8080/a/"/>
952 <link rel="alternate" href="http://hg.example.com:8080/a/"/>
946 <link href="http://hg.example.com:8080/a/rev/8580ff50825a"/>
953 <link href="http://hg.example.com:8080/a/rev/8580ff50825a"/>
947
954
948 rss-log with basedir /
955 rss-log with basedir /
949
956
950 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/rss-log' | grep '<guid'
957 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/rss-log' | grep '<guid'
951 <guid isPermaLink="true">http://hg.example.com:8080/a/rev/8580ff50825a</guid>
958 <guid isPermaLink="true">http://hg.example.com:8080/a/rev/8580ff50825a</guid>
952 $ "$TESTDIR/killdaemons.py"
959 $ "$TESTDIR/killdaemons.py"
953 $ hg serve --config web.baseurl=http://hg.example.com:8080/foo/ -p $HGPORT2 -d \
960 $ hg serve --config web.baseurl=http://hg.example.com:8080/foo/ -p $HGPORT2 -d \
954 > --pid-file=hg.pid --webdir-conf collections.conf \
961 > --pid-file=hg.pid --webdir-conf collections.conf \
955 > -A access-collections-2.log -E error-collections-2.log
962 > -A access-collections-2.log -E error-collections-2.log
956 $ cat hg.pid >> $DAEMON_PIDS
963 $ cat hg.pid >> $DAEMON_PIDS
957
964
958 atom-log with basedir /foo/
965 atom-log with basedir /foo/
959
966
960 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/atom-log' | grep '<link'
967 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/atom-log' | grep '<link'
961 <link rel="self" href="http://hg.example.com:8080/foo/a/atom-log"/>
968 <link rel="self" href="http://hg.example.com:8080/foo/a/atom-log"/>
962 <link rel="alternate" href="http://hg.example.com:8080/foo/a/"/>
969 <link rel="alternate" href="http://hg.example.com:8080/foo/a/"/>
963 <link href="http://hg.example.com:8080/foo/a/rev/8580ff50825a"/>
970 <link href="http://hg.example.com:8080/foo/a/rev/8580ff50825a"/>
964
971
965 rss-log with basedir /foo/
972 rss-log with basedir /foo/
966
973
967 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/rss-log' | grep '<guid'
974 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/a/rss-log' | grep '<guid'
968 <guid isPermaLink="true">http://hg.example.com:8080/foo/a/rev/8580ff50825a</guid>
975 <guid isPermaLink="true">http://hg.example.com:8080/foo/a/rev/8580ff50825a</guid>
969
976
970 paths errors 1
977 paths errors 1
971
978
972 $ cat error-paths-1.log
979 $ cat error-paths-1.log
973
980
974 paths errors 2
981 paths errors 2
975
982
976 $ cat error-paths-2.log
983 $ cat error-paths-2.log
977
984
978 paths errors 3
985 paths errors 3
979
986
980 $ cat error-paths-3.log
987 $ cat error-paths-3.log
981
988
982 paths errors 4
989 paths errors 4
983
990
984 $ cat error-paths-4.log
991 $ cat error-paths-4.log
985
992
986 paths errors 5
993 paths errors 5
987
994
988 $ cat error-paths-5.log
995 $ cat error-paths-5.log
989
996
990 paths errors 6
997 paths errors 6
991
998
992 $ cat error-paths-6.log
999 $ cat error-paths-6.log
993
1000
994 paths errors 7
1001 paths errors 7
995
1002
996 $ cat error-paths-7.log
1003 $ cat error-paths-7.log
997
1004
998 paths errors 8
1005 paths errors 8
999
1006
1000 $ cat error-paths-8.log
1007 $ cat error-paths-8.log
1001
1008
1002 collections errors
1009 collections errors
1003
1010
1004 $ cat error-collections.log
1011 $ cat error-collections.log
1005
1012
1006 collections errors 2
1013 collections errors 2
1007
1014
1008 $ cat error-collections-2.log
1015 $ cat error-collections-2.log
@@ -1,76 +1,80 b''
1 Tests whether or not hgwebdir properly handles various symlink topologies.
1 Tests whether or not hgwebdir properly handles various symlink topologies.
2
2
3 $ "$TESTDIR/hghave" serve symlink || exit 80
3 $ "$TESTDIR/hghave" serve symlink || exit 80
4
5 hide outer repo
6 $ hg init
7
4 $ hg init a
8 $ hg init a
5 $ echo a > a/a
9 $ echo a > a/a
6 $ hg --cwd a ci -Ama -d'1 0'
10 $ hg --cwd a ci -Ama -d'1 0'
7 adding a
11 adding a
8 $ mkdir webdir
12 $ mkdir webdir
9 $ cd webdir
13 $ cd webdir
10 $ hg init b
14 $ hg init b
11 $ echo b > b/b
15 $ echo b > b/b
12 $ hg --cwd b ci -Amb -d'2 0'
16 $ hg --cwd b ci -Amb -d'2 0'
13 adding b
17 adding b
14 $ hg init c
18 $ hg init c
15 $ echo c > c/c
19 $ echo c > c/c
16 $ hg --cwd c ci -Amc -d'3 0'
20 $ hg --cwd c ci -Amc -d'3 0'
17 adding c
21 adding c
18 $ ln -s ../a al
22 $ ln -s ../a al
19 $ ln -s ../webdir circle
23 $ ln -s ../webdir circle
20 $ root=`pwd`
24 $ root=`pwd`
21 $ cd ..
25 $ cd ..
22 $ cat > collections.conf <<EOF
26 $ cat > collections.conf <<EOF
23 > [collections]
27 > [collections]
24 > $root=$root
28 > $root=$root
25 > EOF
29 > EOF
26 $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf collections.conf \
30 $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf collections.conf \
27 > -A access-collections.log -E error-collections.log
31 > -A access-collections.log -E error-collections.log
28 $ cat hg.pid >> $DAEMON_PIDS
32 $ cat hg.pid >> $DAEMON_PIDS
29
33
30 should succeed
34 should succeed
31
35
32 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
36 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
33 200 Script output follows
37 200 Script output follows
34
38
35
39
36 /al/
40 /al/
37 /b/
41 /b/
38 /c/
42 /c/
39
43
40 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/al/file/tip/a?style=raw'
44 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/al/file/tip/a?style=raw'
41 200 Script output follows
45 200 Script output follows
42
46
43 a
47 a
44 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/b/file/tip/b?style=raw'
48 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/b/file/tip/b?style=raw'
45 200 Script output follows
49 200 Script output follows
46
50
47 b
51 b
48 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/c/file/tip/c?style=raw'
52 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/c/file/tip/c?style=raw'
49 200 Script output follows
53 200 Script output follows
50
54
51 c
55 c
52
56
53 should fail
57 should fail
54
58
55 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/circle/al/file/tip/a?style=raw'
59 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/circle/al/file/tip/a?style=raw'
56 404 Not Found
60 404 Not Found
57
61
58
62
59 error: repository circle/al/file/tip/a not found
63 error: repository circle/al/file/tip/a not found
60 [1]
64 [1]
61 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/circle/b/file/tip/a?style=raw'
65 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/circle/b/file/tip/a?style=raw'
62 404 Not Found
66 404 Not Found
63
67
64
68
65 error: repository circle/b/file/tip/a not found
69 error: repository circle/b/file/tip/a not found
66 [1]
70 [1]
67 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/circle/c/file/tip/a?style=raw'
71 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/circle/c/file/tip/a?style=raw'
68 404 Not Found
72 404 Not Found
69
73
70
74
71 error: repository circle/c/file/tip/a not found
75 error: repository circle/c/file/tip/a not found
72 [1]
76 [1]
73
77
74 collections errors
78 collections errors
75
79
76 $ cat error-collections.log
80 $ cat error-collections.log
@@ -1,36 +1,40 b''
1 Translations are optional:
1 Translations are optional:
2
2
3 $ "$TESTDIR/hghave" gettext || exit 80
3 $ "$TESTDIR/hghave" gettext || exit 80
4
4
5 #if no-outer-repo
6
5 Test that translations are compiled and installed correctly.
7 Test that translations are compiled and installed correctly.
6
8
7 Default encoding in tests is "ascii" and the translation is encoded
9 Default encoding in tests is "ascii" and the translation is encoded
8 using the "replace" error handler:
10 using the "replace" error handler:
9
11
10 $ LANGUAGE=pt_BR hg tip
12 $ LANGUAGE=pt_BR hg tip
11 abortado: n?o foi encontrado um reposit?rio em '$TESTTMP' (.hg n?o encontrado)!
13 abortado: n?o foi encontrado um reposit?rio em '$TESTTMP' (.hg n?o encontrado)!
12 [255]
14 [255]
13
15
14 Using a more accomodating encoding:
16 Using a more accomodating encoding:
15
17
16 $ HGENCODING=UTF-8 LANGUAGE=pt_BR hg tip
18 $ HGENCODING=UTF-8 LANGUAGE=pt_BR hg tip
17 abortado: n\xc3\xa3o foi encontrado um reposit\xc3\xb3rio em '$TESTTMP' (.hg n\xc3\xa3o encontrado)! (esc)
19 abortado: n\xc3\xa3o foi encontrado um reposit\xc3\xb3rio em '$TESTTMP' (.hg n\xc3\xa3o encontrado)! (esc)
18 [255]
20 [255]
19
21
20 Different encoding:
22 Different encoding:
21
23
22 $ HGENCODING=Latin-1 LANGUAGE=pt_BR hg tip
24 $ HGENCODING=Latin-1 LANGUAGE=pt_BR hg tip
23 abortado: n\xe3o foi encontrado um reposit\xf3rio em '$TESTTMP' (.hg n\xe3o encontrado)! (esc)
25 abortado: n\xe3o foi encontrado um reposit\xf3rio em '$TESTTMP' (.hg n\xe3o encontrado)! (esc)
24 [255]
26 [255]
25
27
28 #endif
29
26 Test keyword search in translated help text:
30 Test keyword search in translated help text:
27
31
28 $ HGENCODING=UTF-8 LANGUAGE=de hg help -k blΓ€ttern
32 $ HGENCODING=UTF-8 LANGUAGE=de hg help -k blΓ€ttern
29 Topics:
33 Topics:
30
34
31 extensions Benutzung erweiterter Funktionen
35 extensions Benutzung erweiterter Funktionen
32
36
33 Erweiterungen:
37 Erweiterungen:
34
38
35 pager Verwendet einen externen Pager zum Bl\xc3\xa4ttern in der Ausgabe von Befehlen (esc)
39 pager Verwendet einen externen Pager zum Bl\xc3\xa4ttern in der Ausgabe von Befehlen (esc)
36
40
@@ -1,1131 +1,1134 b''
1 $ "$TESTDIR/hghave" unix-permissions serve || exit 80
1 $ "$TESTDIR/hghave" unix-permissions serve || exit 80
2
2
3 $ cat <<EOF >> $HGRCPATH
3 $ cat <<EOF >> $HGRCPATH
4 > [extensions]
4 > [extensions]
5 > keyword =
5 > keyword =
6 > mq =
6 > mq =
7 > notify =
7 > notify =
8 > record =
8 > record =
9 > transplant =
9 > transplant =
10 > [ui]
10 > [ui]
11 > interactive = true
11 > interactive = true
12 > EOF
12 > EOF
13
13
14 hide outer repo
15 $ hg init
16
14 Run kwdemo before [keyword] files are set up
17 Run kwdemo before [keyword] files are set up
15 as it would succeed without uisetup otherwise
18 as it would succeed without uisetup otherwise
16
19
17 $ hg --quiet kwdemo
20 $ hg --quiet kwdemo
18 [extensions]
21 [extensions]
19 keyword =
22 keyword =
20 [keyword]
23 [keyword]
21 demo.txt =
24 demo.txt =
22 [keywordset]
25 [keywordset]
23 svn = False
26 svn = False
24 [keywordmaps]
27 [keywordmaps]
25 Author = {author|user}
28 Author = {author|user}
26 Date = {date|utcdate}
29 Date = {date|utcdate}
27 Header = {root}/{file},v {node|short} {date|utcdate} {author|user}
30 Header = {root}/{file},v {node|short} {date|utcdate} {author|user}
28 Id = {file|basename},v {node|short} {date|utcdate} {author|user}
31 Id = {file|basename},v {node|short} {date|utcdate} {author|user}
29 RCSFile = {file|basename},v
32 RCSFile = {file|basename},v
30 RCSfile = {file|basename},v
33 RCSfile = {file|basename},v
31 Revision = {node|short}
34 Revision = {node|short}
32 Source = {root}/{file},v
35 Source = {root}/{file},v
33 $Author: test $
36 $Author: test $
34 $Date: ????/??/?? ??:??:?? $ (glob)
37 $Date: ????/??/?? ??:??:?? $ (glob)
35 $Header: */demo.txt,v ???????????? ????/??/?? ??:??:?? test $ (glob)
38 $Header: */demo.txt,v ???????????? ????/??/?? ??:??:?? test $ (glob)
36 $Id: demo.txt,v ???????????? ????/??/?? ??:??:?? test $ (glob)
39 $Id: demo.txt,v ???????????? ????/??/?? ??:??:?? test $ (glob)
37 $RCSFile: demo.txt,v $
40 $RCSFile: demo.txt,v $
38 $RCSfile: demo.txt,v $
41 $RCSfile: demo.txt,v $
39 $Revision: ???????????? $ (glob)
42 $Revision: ???????????? $ (glob)
40 $Source: */demo.txt,v $ (glob)
43 $Source: */demo.txt,v $ (glob)
41
44
42 $ hg --quiet kwdemo "Branch = {branches}"
45 $ hg --quiet kwdemo "Branch = {branches}"
43 [extensions]
46 [extensions]
44 keyword =
47 keyword =
45 [keyword]
48 [keyword]
46 demo.txt =
49 demo.txt =
47 [keywordset]
50 [keywordset]
48 svn = False
51 svn = False
49 [keywordmaps]
52 [keywordmaps]
50 Branch = {branches}
53 Branch = {branches}
51 $Branch: demobranch $
54 $Branch: demobranch $
52
55
53 $ cat <<EOF >> $HGRCPATH
56 $ cat <<EOF >> $HGRCPATH
54 > [keyword]
57 > [keyword]
55 > ** =
58 > ** =
56 > b = ignore
59 > b = ignore
57 > i = ignore
60 > i = ignore
58 > [hooks]
61 > [hooks]
59 > EOF
62 > EOF
60 $ cp $HGRCPATH $HGRCPATH.nohooks
63 $ cp $HGRCPATH $HGRCPATH.nohooks
61 > cat <<EOF >> $HGRCPATH
64 > cat <<EOF >> $HGRCPATH
62 > commit=
65 > commit=
63 > commit.test=cp a hooktest
66 > commit.test=cp a hooktest
64 > EOF
67 > EOF
65
68
66 $ hg init Test-bndl
69 $ hg init Test-bndl
67 $ cd Test-bndl
70 $ cd Test-bndl
68
71
69 kwshrink should exit silently in empty/invalid repo
72 kwshrink should exit silently in empty/invalid repo
70
73
71 $ hg kwshrink
74 $ hg kwshrink
72
75
73 Symlinks cannot be created on Windows.
76 Symlinks cannot be created on Windows.
74 A bundle to test this was made with:
77 A bundle to test this was made with:
75 hg init t
78 hg init t
76 cd t
79 cd t
77 echo a > a
80 echo a > a
78 ln -s a sym
81 ln -s a sym
79 hg add sym
82 hg add sym
80 hg ci -m addsym -u mercurial
83 hg ci -m addsym -u mercurial
81 hg bundle --base null ../test-keyword.hg
84 hg bundle --base null ../test-keyword.hg
82
85
83 $ hg pull -u "$TESTDIR"/bundles/test-keyword.hg
86 $ hg pull -u "$TESTDIR"/bundles/test-keyword.hg
84 pulling from *test-keyword.hg (glob)
87 pulling from *test-keyword.hg (glob)
85 requesting all changes
88 requesting all changes
86 adding changesets
89 adding changesets
87 adding manifests
90 adding manifests
88 adding file changes
91 adding file changes
89 added 1 changesets with 1 changes to 1 files
92 added 1 changesets with 1 changes to 1 files
90 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
93 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
91
94
92 $ echo 'expand $Id$' > a
95 $ echo 'expand $Id$' > a
93 $ echo 'do not process $Id:' >> a
96 $ echo 'do not process $Id:' >> a
94 $ echo 'xxx $' >> a
97 $ echo 'xxx $' >> a
95 $ echo 'ignore $Id$' > b
98 $ echo 'ignore $Id$' > b
96
99
97 Output files as they were created
100 Output files as they were created
98
101
99 $ cat a b
102 $ cat a b
100 expand $Id$
103 expand $Id$
101 do not process $Id:
104 do not process $Id:
102 xxx $
105 xxx $
103 ignore $Id$
106 ignore $Id$
104
107
105 no kwfiles
108 no kwfiles
106
109
107 $ hg kwfiles
110 $ hg kwfiles
108
111
109 untracked candidates
112 untracked candidates
110
113
111 $ hg -v kwfiles --unknown
114 $ hg -v kwfiles --unknown
112 k a
115 k a
113
116
114 Add files and check status
117 Add files and check status
115
118
116 $ hg addremove
119 $ hg addremove
117 adding a
120 adding a
118 adding b
121 adding b
119 $ hg status
122 $ hg status
120 A a
123 A a
121 A b
124 A b
122
125
123
126
124 Default keyword expansion including commit hook
127 Default keyword expansion including commit hook
125 Interrupted commit should not change state or run commit hook
128 Interrupted commit should not change state or run commit hook
126
129
127 $ hg --debug commit
130 $ hg --debug commit
128 abort: empty commit message
131 abort: empty commit message
129 [255]
132 [255]
130 $ hg status
133 $ hg status
131 A a
134 A a
132 A b
135 A b
133
136
134 Commit with several checks
137 Commit with several checks
135
138
136 $ hg --debug commit -mabsym -u 'User Name <user@example.com>'
139 $ hg --debug commit -mabsym -u 'User Name <user@example.com>'
137 a
140 a
138 b
141 b
139 overwriting a expanding keywords
142 overwriting a expanding keywords
140 running hook commit.test: cp a hooktest
143 running hook commit.test: cp a hooktest
141 committed changeset 1:ef63ca68695bc9495032c6fda1350c71e6d256e9
144 committed changeset 1:ef63ca68695bc9495032c6fda1350c71e6d256e9
142 $ hg status
145 $ hg status
143 ? hooktest
146 ? hooktest
144 $ hg debugrebuildstate
147 $ hg debugrebuildstate
145 $ hg --quiet identify
148 $ hg --quiet identify
146 ef63ca68695b
149 ef63ca68695b
147
150
148 cat files in working directory with keywords expanded
151 cat files in working directory with keywords expanded
149
152
150 $ cat a b
153 $ cat a b
151 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
154 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
152 do not process $Id:
155 do not process $Id:
153 xxx $
156 xxx $
154 ignore $Id$
157 ignore $Id$
155
158
156 hg cat files and symlink, no expansion
159 hg cat files and symlink, no expansion
157
160
158 $ hg cat sym a b && echo
161 $ hg cat sym a b && echo
159 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
162 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
160 do not process $Id:
163 do not process $Id:
161 xxx $
164 xxx $
162 ignore $Id$
165 ignore $Id$
163 a
166 a
164
167
165 $ diff a hooktest
168 $ diff a hooktest
166
169
167 $ cp $HGRCPATH.nohooks $HGRCPATH
170 $ cp $HGRCPATH.nohooks $HGRCPATH
168 $ rm hooktest
171 $ rm hooktest
169
172
170 hg status of kw-ignored binary file starting with '\1\n'
173 hg status of kw-ignored binary file starting with '\1\n'
171
174
172 >>> open("i", "wb").write("\1\nfoo")
175 >>> open("i", "wb").write("\1\nfoo")
173 $ hg -q commit -Am metasep i
176 $ hg -q commit -Am metasep i
174 $ hg status
177 $ hg status
175 >>> open("i", "wb").write("\1\nbar")
178 >>> open("i", "wb").write("\1\nbar")
176 $ hg status
179 $ hg status
177 M i
180 M i
178 $ hg -q commit -m "modify metasep" i
181 $ hg -q commit -m "modify metasep" i
179 $ hg status --rev 2:3
182 $ hg status --rev 2:3
180 M i
183 M i
181 $ touch empty
184 $ touch empty
182 $ hg -q commit -A -m "another file"
185 $ hg -q commit -A -m "another file"
183 $ hg status -A --rev 3:4 i
186 $ hg status -A --rev 3:4 i
184 C i
187 C i
185
188
186 $ hg -q strip -n 2
189 $ hg -q strip -n 2
187
190
188 Test hook execution
191 Test hook execution
189
192
190 bundle
193 bundle
191
194
192 $ hg bundle --base null ../kw.hg
195 $ hg bundle --base null ../kw.hg
193 2 changesets found
196 2 changesets found
194 $ cd ..
197 $ cd ..
195 $ hg init Test
198 $ hg init Test
196 $ cd Test
199 $ cd Test
197
200
198 Notify on pull to check whether keywords stay as is in email
201 Notify on pull to check whether keywords stay as is in email
199 ie. if patch.diff wrapper acts as it should
202 ie. if patch.diff wrapper acts as it should
200
203
201 $ cat <<EOF >> $HGRCPATH
204 $ cat <<EOF >> $HGRCPATH
202 > [hooks]
205 > [hooks]
203 > incoming.notify = python:hgext.notify.hook
206 > incoming.notify = python:hgext.notify.hook
204 > [notify]
207 > [notify]
205 > sources = pull
208 > sources = pull
206 > diffstat = False
209 > diffstat = False
207 > maxsubject = 15
210 > maxsubject = 15
208 > [reposubs]
211 > [reposubs]
209 > * = Test
212 > * = Test
210 > EOF
213 > EOF
211
214
212 Pull from bundle and trigger notify
215 Pull from bundle and trigger notify
213
216
214 $ hg pull -u ../kw.hg
217 $ hg pull -u ../kw.hg
215 pulling from ../kw.hg
218 pulling from ../kw.hg
216 requesting all changes
219 requesting all changes
217 adding changesets
220 adding changesets
218 adding manifests
221 adding manifests
219 adding file changes
222 adding file changes
220 added 2 changesets with 3 changes to 3 files
223 added 2 changesets with 3 changes to 3 files
221 Content-Type: text/plain; charset="us-ascii"
224 Content-Type: text/plain; charset="us-ascii"
222 MIME-Version: 1.0
225 MIME-Version: 1.0
223 Content-Transfer-Encoding: 7bit
226 Content-Transfer-Encoding: 7bit
224 Date: * (glob)
227 Date: * (glob)
225 Subject: changeset in...
228 Subject: changeset in...
226 From: mercurial
229 From: mercurial
227 X-Hg-Notification: changeset a2392c293916
230 X-Hg-Notification: changeset a2392c293916
228 Message-Id: <hg.a2392c293916*> (glob)
231 Message-Id: <hg.a2392c293916*> (glob)
229 To: Test
232 To: Test
230
233
231 changeset a2392c293916 in $TESTTMP/Test (glob)
234 changeset a2392c293916 in $TESTTMP/Test (glob)
232 details: $TESTTMP/Test?cmd=changeset;node=a2392c293916
235 details: $TESTTMP/Test?cmd=changeset;node=a2392c293916
233 description:
236 description:
234 addsym
237 addsym
235
238
236 diffs (6 lines):
239 diffs (6 lines):
237
240
238 diff -r 000000000000 -r a2392c293916 sym
241 diff -r 000000000000 -r a2392c293916 sym
239 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
242 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
240 +++ b/sym Sat Feb 09 20:25:47 2008 +0100
243 +++ b/sym Sat Feb 09 20:25:47 2008 +0100
241 @@ -0,0 +1,1 @@
244 @@ -0,0 +1,1 @@
242 +a
245 +a
243 \ No newline at end of file
246 \ No newline at end of file
244 Content-Type: text/plain; charset="us-ascii"
247 Content-Type: text/plain; charset="us-ascii"
245 MIME-Version: 1.0
248 MIME-Version: 1.0
246 Content-Transfer-Encoding: 7bit
249 Content-Transfer-Encoding: 7bit
247 Date:* (glob)
250 Date:* (glob)
248 Subject: changeset in...
251 Subject: changeset in...
249 From: User Name <user@example.com>
252 From: User Name <user@example.com>
250 X-Hg-Notification: changeset ef63ca68695b
253 X-Hg-Notification: changeset ef63ca68695b
251 Message-Id: <hg.ef63ca68695b*> (glob)
254 Message-Id: <hg.ef63ca68695b*> (glob)
252 To: Test
255 To: Test
253
256
254 changeset ef63ca68695b in $TESTTMP/Test (glob)
257 changeset ef63ca68695b in $TESTTMP/Test (glob)
255 details: $TESTTMP/Test?cmd=changeset;node=ef63ca68695b
258 details: $TESTTMP/Test?cmd=changeset;node=ef63ca68695b
256 description:
259 description:
257 absym
260 absym
258
261
259 diffs (12 lines):
262 diffs (12 lines):
260
263
261 diff -r a2392c293916 -r ef63ca68695b a
264 diff -r a2392c293916 -r ef63ca68695b a
262 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
265 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
263 +++ b/a Thu Jan 01 00:00:00 1970 +0000
266 +++ b/a Thu Jan 01 00:00:00 1970 +0000
264 @@ -0,0 +1,3 @@
267 @@ -0,0 +1,3 @@
265 +expand $Id$
268 +expand $Id$
266 +do not process $Id:
269 +do not process $Id:
267 +xxx $
270 +xxx $
268 diff -r a2392c293916 -r ef63ca68695b b
271 diff -r a2392c293916 -r ef63ca68695b b
269 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
272 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
270 +++ b/b Thu Jan 01 00:00:00 1970 +0000
273 +++ b/b Thu Jan 01 00:00:00 1970 +0000
271 @@ -0,0 +1,1 @@
274 @@ -0,0 +1,1 @@
272 +ignore $Id$
275 +ignore $Id$
273 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
276 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
274
277
275 $ cp $HGRCPATH.nohooks $HGRCPATH
278 $ cp $HGRCPATH.nohooks $HGRCPATH
276
279
277 Touch files and check with status
280 Touch files and check with status
278
281
279 $ touch a b
282 $ touch a b
280 $ hg status
283 $ hg status
281
284
282 Update and expand
285 Update and expand
283
286
284 $ rm sym a b
287 $ rm sym a b
285 $ hg update -C
288 $ hg update -C
286 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
289 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
287 $ cat a b
290 $ cat a b
288 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
291 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
289 do not process $Id:
292 do not process $Id:
290 xxx $
293 xxx $
291 ignore $Id$
294 ignore $Id$
292
295
293 Check whether expansion is filewise and file mode is preserved
296 Check whether expansion is filewise and file mode is preserved
294
297
295 $ echo '$Id$' > c
298 $ echo '$Id$' > c
296 $ echo 'tests for different changenodes' >> c
299 $ echo 'tests for different changenodes' >> c
297 $ chmod 600 c
300 $ chmod 600 c
298 $ ls -l c | cut -b 1-10
301 $ ls -l c | cut -b 1-10
299 -rw-------
302 -rw-------
300
303
301 commit file c
304 commit file c
302
305
303 $ hg commit -A -mcndiff -d '1 0' -u 'User Name <user@example.com>'
306 $ hg commit -A -mcndiff -d '1 0' -u 'User Name <user@example.com>'
304 adding c
307 adding c
305 $ ls -l c | cut -b 1-10
308 $ ls -l c | cut -b 1-10
306 -rw-------
309 -rw-------
307
310
308 force expansion
311 force expansion
309
312
310 $ hg -v kwexpand
313 $ hg -v kwexpand
311 overwriting a expanding keywords
314 overwriting a expanding keywords
312 overwriting c expanding keywords
315 overwriting c expanding keywords
313
316
314 compare changenodes in a and c
317 compare changenodes in a and c
315
318
316 $ cat a c
319 $ cat a c
317 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
320 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
318 do not process $Id:
321 do not process $Id:
319 xxx $
322 xxx $
320 $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $
323 $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $
321 tests for different changenodes
324 tests for different changenodes
322
325
323 record
326 record
324
327
325 $ echo '$Id$' > r
328 $ echo '$Id$' > r
326 $ hg add r
329 $ hg add r
327
330
328 record chunk
331 record chunk
329
332
330 >>> lines = open('a').readlines()
333 >>> lines = open('a').readlines()
331 >>> lines.insert(1, 'foo\n')
334 >>> lines.insert(1, 'foo\n')
332 >>> lines.append('bar\n')
335 >>> lines.append('bar\n')
333 >>> open('a', 'w').writelines(lines)
336 >>> open('a', 'w').writelines(lines)
334 $ hg record -d '1 10' -m rectest a<<EOF
337 $ hg record -d '1 10' -m rectest a<<EOF
335 > y
338 > y
336 > y
339 > y
337 > n
340 > n
338 > EOF
341 > EOF
339 diff --git a/a b/a
342 diff --git a/a b/a
340 2 hunks, 2 lines changed
343 2 hunks, 2 lines changed
341 examine changes to 'a'? [Ynesfdaq?]
344 examine changes to 'a'? [Ynesfdaq?]
342 @@ -1,3 +1,4 @@
345 @@ -1,3 +1,4 @@
343 expand $Id$
346 expand $Id$
344 +foo
347 +foo
345 do not process $Id:
348 do not process $Id:
346 xxx $
349 xxx $
347 record change 1/2 to 'a'? [Ynesfdaq?]
350 record change 1/2 to 'a'? [Ynesfdaq?]
348 @@ -2,2 +3,3 @@
351 @@ -2,2 +3,3 @@
349 do not process $Id:
352 do not process $Id:
350 xxx $
353 xxx $
351 +bar
354 +bar
352 record change 2/2 to 'a'? [Ynesfdaq?]
355 record change 2/2 to 'a'? [Ynesfdaq?]
353
356
354 $ hg identify
357 $ hg identify
355 d17e03c92c97+ tip
358 d17e03c92c97+ tip
356 $ hg status
359 $ hg status
357 M a
360 M a
358 A r
361 A r
359
362
360 Cat modified file a
363 Cat modified file a
361
364
362 $ cat a
365 $ cat a
363 expand $Id: a,v d17e03c92c97 1970/01/01 00:00:01 test $
366 expand $Id: a,v d17e03c92c97 1970/01/01 00:00:01 test $
364 foo
367 foo
365 do not process $Id:
368 do not process $Id:
366 xxx $
369 xxx $
367 bar
370 bar
368
371
369 Diff remaining chunk
372 Diff remaining chunk
370
373
371 $ hg diff a
374 $ hg diff a
372 diff -r d17e03c92c97 a
375 diff -r d17e03c92c97 a
373 --- a/a Wed Dec 31 23:59:51 1969 -0000
376 --- a/a Wed Dec 31 23:59:51 1969 -0000
374 +++ b/a * (glob)
377 +++ b/a * (glob)
375 @@ -2,3 +2,4 @@
378 @@ -2,3 +2,4 @@
376 foo
379 foo
377 do not process $Id:
380 do not process $Id:
378 xxx $
381 xxx $
379 +bar
382 +bar
380
383
381 $ hg rollback
384 $ hg rollback
382 repository tip rolled back to revision 2 (undo commit)
385 repository tip rolled back to revision 2 (undo commit)
383 working directory now based on revision 2
386 working directory now based on revision 2
384
387
385 Record all chunks in file a
388 Record all chunks in file a
386
389
387 $ echo foo > msg
390 $ echo foo > msg
388
391
389 - do not use "hg record -m" here!
392 - do not use "hg record -m" here!
390
393
391 $ hg record -l msg -d '1 11' a<<EOF
394 $ hg record -l msg -d '1 11' a<<EOF
392 > y
395 > y
393 > y
396 > y
394 > y
397 > y
395 > EOF
398 > EOF
396 diff --git a/a b/a
399 diff --git a/a b/a
397 2 hunks, 2 lines changed
400 2 hunks, 2 lines changed
398 examine changes to 'a'? [Ynesfdaq?]
401 examine changes to 'a'? [Ynesfdaq?]
399 @@ -1,3 +1,4 @@
402 @@ -1,3 +1,4 @@
400 expand $Id$
403 expand $Id$
401 +foo
404 +foo
402 do not process $Id:
405 do not process $Id:
403 xxx $
406 xxx $
404 record change 1/2 to 'a'? [Ynesfdaq?]
407 record change 1/2 to 'a'? [Ynesfdaq?]
405 @@ -2,2 +3,3 @@
408 @@ -2,2 +3,3 @@
406 do not process $Id:
409 do not process $Id:
407 xxx $
410 xxx $
408 +bar
411 +bar
409 record change 2/2 to 'a'? [Ynesfdaq?]
412 record change 2/2 to 'a'? [Ynesfdaq?]
410
413
411 File a should be clean
414 File a should be clean
412
415
413 $ hg status -A a
416 $ hg status -A a
414 C a
417 C a
415
418
416 rollback and revert expansion
419 rollback and revert expansion
417
420
418 $ cat a
421 $ cat a
419 expand $Id: a,v 59f969a3b52c 1970/01/01 00:00:01 test $
422 expand $Id: a,v 59f969a3b52c 1970/01/01 00:00:01 test $
420 foo
423 foo
421 do not process $Id:
424 do not process $Id:
422 xxx $
425 xxx $
423 bar
426 bar
424 $ hg --verbose rollback
427 $ hg --verbose rollback
425 repository tip rolled back to revision 2 (undo commit)
428 repository tip rolled back to revision 2 (undo commit)
426 working directory now based on revision 2
429 working directory now based on revision 2
427 overwriting a expanding keywords
430 overwriting a expanding keywords
428 $ hg status a
431 $ hg status a
429 M a
432 M a
430 $ cat a
433 $ cat a
431 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
434 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
432 foo
435 foo
433 do not process $Id:
436 do not process $Id:
434 xxx $
437 xxx $
435 bar
438 bar
436 $ echo '$Id$' > y
439 $ echo '$Id$' > y
437 $ echo '$Id$' > z
440 $ echo '$Id$' > z
438 $ hg add y
441 $ hg add y
439 $ hg commit -Am "rollback only" z
442 $ hg commit -Am "rollback only" z
440 $ cat z
443 $ cat z
441 $Id: z,v 45a5d3adce53 1970/01/01 00:00:00 test $
444 $Id: z,v 45a5d3adce53 1970/01/01 00:00:00 test $
442 $ hg --verbose rollback
445 $ hg --verbose rollback
443 repository tip rolled back to revision 2 (undo commit)
446 repository tip rolled back to revision 2 (undo commit)
444 working directory now based on revision 2
447 working directory now based on revision 2
445 overwriting z shrinking keywords
448 overwriting z shrinking keywords
446
449
447 Only z should be overwritten
450 Only z should be overwritten
448
451
449 $ hg status a y z
452 $ hg status a y z
450 M a
453 M a
451 A y
454 A y
452 A z
455 A z
453 $ cat z
456 $ cat z
454 $Id$
457 $Id$
455 $ hg forget y z
458 $ hg forget y z
456 $ rm y z
459 $ rm y z
457
460
458 record added file alone
461 record added file alone
459
462
460 $ hg -v record -l msg -d '1 12' r<<EOF
463 $ hg -v record -l msg -d '1 12' r<<EOF
461 > y
464 > y
462 > EOF
465 > EOF
463 diff --git a/r b/r
466 diff --git a/r b/r
464 new file mode 100644
467 new file mode 100644
465 examine changes to 'r'? [Ynesfdaq?]
468 examine changes to 'r'? [Ynesfdaq?]
466 r
469 r
467 committed changeset 3:899491280810
470 committed changeset 3:899491280810
468 overwriting r expanding keywords
471 overwriting r expanding keywords
469 - status call required for dirstate.normallookup() check
472 - status call required for dirstate.normallookup() check
470 $ hg status r
473 $ hg status r
471 $ hg --verbose rollback
474 $ hg --verbose rollback
472 repository tip rolled back to revision 2 (undo commit)
475 repository tip rolled back to revision 2 (undo commit)
473 working directory now based on revision 2
476 working directory now based on revision 2
474 overwriting r shrinking keywords
477 overwriting r shrinking keywords
475 $ hg forget r
478 $ hg forget r
476 $ rm msg r
479 $ rm msg r
477 $ hg update -C
480 $ hg update -C
478 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
481 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
479
482
480 record added keyword ignored file
483 record added keyword ignored file
481
484
482 $ echo '$Id$' > i
485 $ echo '$Id$' > i
483 $ hg add i
486 $ hg add i
484 $ hg --verbose record -d '1 13' -m recignored<<EOF
487 $ hg --verbose record -d '1 13' -m recignored<<EOF
485 > y
488 > y
486 > EOF
489 > EOF
487 diff --git a/i b/i
490 diff --git a/i b/i
488 new file mode 100644
491 new file mode 100644
489 examine changes to 'i'? [Ynesfdaq?]
492 examine changes to 'i'? [Ynesfdaq?]
490 i
493 i
491 committed changeset 3:5f40fe93bbdc
494 committed changeset 3:5f40fe93bbdc
492 $ cat i
495 $ cat i
493 $Id$
496 $Id$
494 $ hg -q rollback
497 $ hg -q rollback
495 $ hg forget i
498 $ hg forget i
496 $ rm i
499 $ rm i
497
500
498 amend
501 amend
499
502
500 $ echo amend >> a
503 $ echo amend >> a
501 $ echo amend >> b
504 $ echo amend >> b
502 $ hg -q commit -d '1 14' -m 'prepare amend'
505 $ hg -q commit -d '1 14' -m 'prepare amend'
503
506
504 $ hg --debug commit --amend -d '1 15' -m 'amend without changes' | grep keywords
507 $ hg --debug commit --amend -d '1 15' -m 'amend without changes' | grep keywords
505 invalidating branch cache (tip differs)
508 invalidating branch cache (tip differs)
506 overwriting a expanding keywords
509 overwriting a expanding keywords
507 $ hg -q id
510 $ hg -q id
508 a71343332ea9
511 a71343332ea9
509 $ head -1 a
512 $ head -1 a
510 expand $Id: a,v a71343332ea9 1970/01/01 00:00:01 test $
513 expand $Id: a,v a71343332ea9 1970/01/01 00:00:01 test $
511
514
512 $ hg -q strip -n tip
515 $ hg -q strip -n tip
513
516
514 Test patch queue repo
517 Test patch queue repo
515
518
516 $ hg init --mq
519 $ hg init --mq
517 $ hg qimport -r tip -n mqtest.diff
520 $ hg qimport -r tip -n mqtest.diff
518 $ hg commit --mq -m mqtest
521 $ hg commit --mq -m mqtest
519
522
520 Keywords should not be expanded in patch
523 Keywords should not be expanded in patch
521
524
522 $ cat .hg/patches/mqtest.diff
525 $ cat .hg/patches/mqtest.diff
523 # HG changeset patch
526 # HG changeset patch
524 # User User Name <user@example.com>
527 # User User Name <user@example.com>
525 # Date 1 0
528 # Date 1 0
526 # Node ID 40a904bbbe4cd4ab0a1f28411e35db26341a40ad
529 # Node ID 40a904bbbe4cd4ab0a1f28411e35db26341a40ad
527 # Parent ef63ca68695bc9495032c6fda1350c71e6d256e9
530 # Parent ef63ca68695bc9495032c6fda1350c71e6d256e9
528 cndiff
531 cndiff
529
532
530 diff -r ef63ca68695b -r 40a904bbbe4c c
533 diff -r ef63ca68695b -r 40a904bbbe4c c
531 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
534 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
532 +++ b/c Thu Jan 01 00:00:01 1970 +0000
535 +++ b/c Thu Jan 01 00:00:01 1970 +0000
533 @@ -0,0 +1,2 @@
536 @@ -0,0 +1,2 @@
534 +$Id$
537 +$Id$
535 +tests for different changenodes
538 +tests for different changenodes
536
539
537 $ hg qpop
540 $ hg qpop
538 popping mqtest.diff
541 popping mqtest.diff
539 patch queue now empty
542 patch queue now empty
540
543
541 qgoto, implying qpush, should expand
544 qgoto, implying qpush, should expand
542
545
543 $ hg qgoto mqtest.diff
546 $ hg qgoto mqtest.diff
544 applying mqtest.diff
547 applying mqtest.diff
545 now at: mqtest.diff
548 now at: mqtest.diff
546 $ cat c
549 $ cat c
547 $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $
550 $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $
548 tests for different changenodes
551 tests for different changenodes
549 $ hg cat c
552 $ hg cat c
550 $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $
553 $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $
551 tests for different changenodes
554 tests for different changenodes
552
555
553 Keywords should not be expanded in filelog
556 Keywords should not be expanded in filelog
554
557
555 $ hg --config 'extensions.keyword=!' cat c
558 $ hg --config 'extensions.keyword=!' cat c
556 $Id$
559 $Id$
557 tests for different changenodes
560 tests for different changenodes
558
561
559 qpop and move on
562 qpop and move on
560
563
561 $ hg qpop
564 $ hg qpop
562 popping mqtest.diff
565 popping mqtest.diff
563 patch queue now empty
566 patch queue now empty
564
567
565 Copy and show added kwfiles
568 Copy and show added kwfiles
566
569
567 $ hg cp a c
570 $ hg cp a c
568 $ hg kwfiles
571 $ hg kwfiles
569 a
572 a
570 c
573 c
571
574
572 Commit and show expansion in original and copy
575 Commit and show expansion in original and copy
573
576
574 $ hg --debug commit -ma2c -d '1 0' -u 'User Name <user@example.com>'
577 $ hg --debug commit -ma2c -d '1 0' -u 'User Name <user@example.com>'
575 c
578 c
576 c: copy a:0045e12f6c5791aac80ca6cbfd97709a88307292
579 c: copy a:0045e12f6c5791aac80ca6cbfd97709a88307292
577 removing unknown node 40a904bbbe4c from 1-phase boundary
580 removing unknown node 40a904bbbe4c from 1-phase boundary
578 overwriting c expanding keywords
581 overwriting c expanding keywords
579 committed changeset 2:25736cf2f5cbe41f6be4e6784ef6ecf9f3bbcc7d
582 committed changeset 2:25736cf2f5cbe41f6be4e6784ef6ecf9f3bbcc7d
580 $ cat a c
583 $ cat a c
581 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
584 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
582 do not process $Id:
585 do not process $Id:
583 xxx $
586 xxx $
584 expand $Id: c,v 25736cf2f5cb 1970/01/01 00:00:01 user $
587 expand $Id: c,v 25736cf2f5cb 1970/01/01 00:00:01 user $
585 do not process $Id:
588 do not process $Id:
586 xxx $
589 xxx $
587
590
588 Touch copied c and check its status
591 Touch copied c and check its status
589
592
590 $ touch c
593 $ touch c
591 $ hg status
594 $ hg status
592
595
593 Copy kwfile to keyword ignored file unexpanding keywords
596 Copy kwfile to keyword ignored file unexpanding keywords
594
597
595 $ hg --verbose copy a i
598 $ hg --verbose copy a i
596 copying a to i
599 copying a to i
597 overwriting i shrinking keywords
600 overwriting i shrinking keywords
598 $ head -n 1 i
601 $ head -n 1 i
599 expand $Id$
602 expand $Id$
600 $ hg forget i
603 $ hg forget i
601 $ rm i
604 $ rm i
602
605
603 Copy ignored file to ignored file: no overwriting
606 Copy ignored file to ignored file: no overwriting
604
607
605 $ hg --verbose copy b i
608 $ hg --verbose copy b i
606 copying b to i
609 copying b to i
607 $ hg forget i
610 $ hg forget i
608 $ rm i
611 $ rm i
609
612
610 cp symlink file; hg cp -A symlink file (part1)
613 cp symlink file; hg cp -A symlink file (part1)
611 - copied symlink points to kwfile: overwrite
614 - copied symlink points to kwfile: overwrite
612
615
613 $ cp sym i
616 $ cp sym i
614 $ ls -l i
617 $ ls -l i
615 -rw-r--r--* (glob)
618 -rw-r--r--* (glob)
616 $ head -1 i
619 $ head -1 i
617 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
620 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
618 $ hg copy --after --verbose sym i
621 $ hg copy --after --verbose sym i
619 copying sym to i
622 copying sym to i
620 overwriting i shrinking keywords
623 overwriting i shrinking keywords
621 $ head -1 i
624 $ head -1 i
622 expand $Id$
625 expand $Id$
623 $ hg forget i
626 $ hg forget i
624 $ rm i
627 $ rm i
625
628
626 Test different options of hg kwfiles
629 Test different options of hg kwfiles
627
630
628 $ hg kwfiles
631 $ hg kwfiles
629 a
632 a
630 c
633 c
631 $ hg -v kwfiles --ignore
634 $ hg -v kwfiles --ignore
632 I b
635 I b
633 I sym
636 I sym
634 $ hg kwfiles --all
637 $ hg kwfiles --all
635 K a
638 K a
636 K c
639 K c
637 I b
640 I b
638 I sym
641 I sym
639
642
640 Diff specific revision
643 Diff specific revision
641
644
642 $ hg diff --rev 1
645 $ hg diff --rev 1
643 diff -r ef63ca68695b c
646 diff -r ef63ca68695b c
644 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
647 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
645 +++ b/c * (glob)
648 +++ b/c * (glob)
646 @@ -0,0 +1,3 @@
649 @@ -0,0 +1,3 @@
647 +expand $Id$
650 +expand $Id$
648 +do not process $Id:
651 +do not process $Id:
649 +xxx $
652 +xxx $
650
653
651 Status after rollback:
654 Status after rollback:
652
655
653 $ hg rollback
656 $ hg rollback
654 repository tip rolled back to revision 1 (undo commit)
657 repository tip rolled back to revision 1 (undo commit)
655 working directory now based on revision 1
658 working directory now based on revision 1
656 $ hg status
659 $ hg status
657 A c
660 A c
658 $ hg update --clean
661 $ hg update --clean
659 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
662 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
660
663
661 #if symlink
664 #if symlink
662
665
663 cp symlink file; hg cp -A symlink file (part2)
666 cp symlink file; hg cp -A symlink file (part2)
664 - copied symlink points to kw ignored file: do not overwrite
667 - copied symlink points to kw ignored file: do not overwrite
665
668
666 $ cat a > i
669 $ cat a > i
667 $ ln -s i symignored
670 $ ln -s i symignored
668 $ hg commit -Am 'fake expansion in ignored and symlink' i symignored
671 $ hg commit -Am 'fake expansion in ignored and symlink' i symignored
669 $ cp symignored x
672 $ cp symignored x
670 $ hg copy --after --verbose symignored x
673 $ hg copy --after --verbose symignored x
671 copying symignored to x
674 copying symignored to x
672 $ head -n 1 x
675 $ head -n 1 x
673 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
676 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
674 $ hg forget x
677 $ hg forget x
675 $ rm x
678 $ rm x
676
679
677 $ hg rollback
680 $ hg rollback
678 repository tip rolled back to revision 1 (undo commit)
681 repository tip rolled back to revision 1 (undo commit)
679 working directory now based on revision 1
682 working directory now based on revision 1
680 $ hg update --clean
683 $ hg update --clean
681 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
684 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
682 $ rm i symignored
685 $ rm i symignored
683
686
684 #endif
687 #endif
685
688
686 Custom keywordmaps as argument to kwdemo
689 Custom keywordmaps as argument to kwdemo
687
690
688 $ hg --quiet kwdemo "Xinfo = {author}: {desc}"
691 $ hg --quiet kwdemo "Xinfo = {author}: {desc}"
689 [extensions]
692 [extensions]
690 keyword =
693 keyword =
691 [keyword]
694 [keyword]
692 ** =
695 ** =
693 b = ignore
696 b = ignore
694 demo.txt =
697 demo.txt =
695 i = ignore
698 i = ignore
696 [keywordset]
699 [keywordset]
697 svn = False
700 svn = False
698 [keywordmaps]
701 [keywordmaps]
699 Xinfo = {author}: {desc}
702 Xinfo = {author}: {desc}
700 $Xinfo: test: hg keyword configuration and expansion example $
703 $Xinfo: test: hg keyword configuration and expansion example $
701
704
702 Configure custom keywordmaps
705 Configure custom keywordmaps
703
706
704 $ cat <<EOF >>$HGRCPATH
707 $ cat <<EOF >>$HGRCPATH
705 > [keywordmaps]
708 > [keywordmaps]
706 > Id = {file} {node|short} {date|rfc822date} {author|user}
709 > Id = {file} {node|short} {date|rfc822date} {author|user}
707 > Xinfo = {author}: {desc}
710 > Xinfo = {author}: {desc}
708 > EOF
711 > EOF
709
712
710 Cat and hg cat files before custom expansion
713 Cat and hg cat files before custom expansion
711
714
712 $ cat a b
715 $ cat a b
713 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
716 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
714 do not process $Id:
717 do not process $Id:
715 xxx $
718 xxx $
716 ignore $Id$
719 ignore $Id$
717 $ hg cat sym a b && echo
720 $ hg cat sym a b && echo
718 expand $Id: a ef63ca68695b Thu, 01 Jan 1970 00:00:00 +0000 user $
721 expand $Id: a ef63ca68695b Thu, 01 Jan 1970 00:00:00 +0000 user $
719 do not process $Id:
722 do not process $Id:
720 xxx $
723 xxx $
721 ignore $Id$
724 ignore $Id$
722 a
725 a
723
726
724 Write custom keyword and prepare multiline commit message
727 Write custom keyword and prepare multiline commit message
725
728
726 $ echo '$Xinfo$' >> a
729 $ echo '$Xinfo$' >> a
727 $ cat <<EOF >> log
730 $ cat <<EOF >> log
728 > firstline
731 > firstline
729 > secondline
732 > secondline
730 > EOF
733 > EOF
731
734
732 Interrupted commit should not change state
735 Interrupted commit should not change state
733
736
734 $ hg commit
737 $ hg commit
735 abort: empty commit message
738 abort: empty commit message
736 [255]
739 [255]
737 $ hg status
740 $ hg status
738 M a
741 M a
739 ? c
742 ? c
740 ? log
743 ? log
741
744
742 Commit with multiline message and custom expansion
745 Commit with multiline message and custom expansion
743
746
744 $ hg --debug commit -l log -d '2 0' -u 'User Name <user@example.com>'
747 $ hg --debug commit -l log -d '2 0' -u 'User Name <user@example.com>'
745 a
748 a
746 removing unknown node 40a904bbbe4c from 1-phase boundary
749 removing unknown node 40a904bbbe4c from 1-phase boundary
747 overwriting a expanding keywords
750 overwriting a expanding keywords
748 committed changeset 2:bb948857c743469b22bbf51f7ec8112279ca5d83
751 committed changeset 2:bb948857c743469b22bbf51f7ec8112279ca5d83
749 $ rm log
752 $ rm log
750
753
751 Stat, verify and show custom expansion (firstline)
754 Stat, verify and show custom expansion (firstline)
752
755
753 $ hg status
756 $ hg status
754 ? c
757 ? c
755 $ hg verify
758 $ hg verify
756 checking changesets
759 checking changesets
757 checking manifests
760 checking manifests
758 crosschecking files in changesets and manifests
761 crosschecking files in changesets and manifests
759 checking files
762 checking files
760 3 files, 3 changesets, 4 total revisions
763 3 files, 3 changesets, 4 total revisions
761 $ cat a b
764 $ cat a b
762 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
765 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
763 do not process $Id:
766 do not process $Id:
764 xxx $
767 xxx $
765 $Xinfo: User Name <user@example.com>: firstline $
768 $Xinfo: User Name <user@example.com>: firstline $
766 ignore $Id$
769 ignore $Id$
767 $ hg cat sym a b && echo
770 $ hg cat sym a b && echo
768 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
771 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
769 do not process $Id:
772 do not process $Id:
770 xxx $
773 xxx $
771 $Xinfo: User Name <user@example.com>: firstline $
774 $Xinfo: User Name <user@example.com>: firstline $
772 ignore $Id$
775 ignore $Id$
773 a
776 a
774
777
775 annotate
778 annotate
776
779
777 $ hg annotate a
780 $ hg annotate a
778 1: expand $Id$
781 1: expand $Id$
779 1: do not process $Id:
782 1: do not process $Id:
780 1: xxx $
783 1: xxx $
781 2: $Xinfo$
784 2: $Xinfo$
782
785
783 remove with status checks
786 remove with status checks
784
787
785 $ hg debugrebuildstate
788 $ hg debugrebuildstate
786 $ hg remove a
789 $ hg remove a
787 $ hg --debug commit -m rma
790 $ hg --debug commit -m rma
788 committed changeset 3:d14c712653769de926994cf7fbb06c8fbd68f012
791 committed changeset 3:d14c712653769de926994cf7fbb06c8fbd68f012
789 $ hg status
792 $ hg status
790 ? c
793 ? c
791
794
792 Rollback, revert, and check expansion
795 Rollback, revert, and check expansion
793
796
794 $ hg rollback
797 $ hg rollback
795 repository tip rolled back to revision 2 (undo commit)
798 repository tip rolled back to revision 2 (undo commit)
796 working directory now based on revision 2
799 working directory now based on revision 2
797 $ hg status
800 $ hg status
798 R a
801 R a
799 ? c
802 ? c
800 $ hg revert --no-backup --rev tip a
803 $ hg revert --no-backup --rev tip a
801 $ cat a
804 $ cat a
802 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
805 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
803 do not process $Id:
806 do not process $Id:
804 xxx $
807 xxx $
805 $Xinfo: User Name <user@example.com>: firstline $
808 $Xinfo: User Name <user@example.com>: firstline $
806
809
807 Clone to test global and local configurations
810 Clone to test global and local configurations
808
811
809 $ cd ..
812 $ cd ..
810
813
811 Expansion in destinaton with global configuration
814 Expansion in destinaton with global configuration
812
815
813 $ hg --quiet clone Test globalconf
816 $ hg --quiet clone Test globalconf
814 $ cat globalconf/a
817 $ cat globalconf/a
815 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
818 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
816 do not process $Id:
819 do not process $Id:
817 xxx $
820 xxx $
818 $Xinfo: User Name <user@example.com>: firstline $
821 $Xinfo: User Name <user@example.com>: firstline $
819
822
820 No expansion in destination with local configuration in origin only
823 No expansion in destination with local configuration in origin only
821
824
822 $ hg --quiet --config 'keyword.**=ignore' clone Test localconf
825 $ hg --quiet --config 'keyword.**=ignore' clone Test localconf
823 $ cat localconf/a
826 $ cat localconf/a
824 expand $Id$
827 expand $Id$
825 do not process $Id:
828 do not process $Id:
826 xxx $
829 xxx $
827 $Xinfo$
830 $Xinfo$
828
831
829 Clone to test incoming
832 Clone to test incoming
830
833
831 $ hg clone -r1 Test Test-a
834 $ hg clone -r1 Test Test-a
832 adding changesets
835 adding changesets
833 adding manifests
836 adding manifests
834 adding file changes
837 adding file changes
835 added 2 changesets with 3 changes to 3 files
838 added 2 changesets with 3 changes to 3 files
836 updating to branch default
839 updating to branch default
837 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
840 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
838 $ cd Test-a
841 $ cd Test-a
839 $ cat <<EOF >> .hg/hgrc
842 $ cat <<EOF >> .hg/hgrc
840 > [paths]
843 > [paths]
841 > default = ../Test
844 > default = ../Test
842 > EOF
845 > EOF
843 $ hg incoming
846 $ hg incoming
844 comparing with $TESTTMP/Test (glob)
847 comparing with $TESTTMP/Test (glob)
845 searching for changes
848 searching for changes
846 changeset: 2:bb948857c743
849 changeset: 2:bb948857c743
847 tag: tip
850 tag: tip
848 user: User Name <user@example.com>
851 user: User Name <user@example.com>
849 date: Thu Jan 01 00:00:02 1970 +0000
852 date: Thu Jan 01 00:00:02 1970 +0000
850 summary: firstline
853 summary: firstline
851
854
852 Imported patch should not be rejected
855 Imported patch should not be rejected
853
856
854 >>> import re
857 >>> import re
855 >>> text = re.sub(r'(Id.*)', r'\1 rejecttest', open('a').read())
858 >>> text = re.sub(r'(Id.*)', r'\1 rejecttest', open('a').read())
856 >>> open('a', 'wb').write(text)
859 >>> open('a', 'wb').write(text)
857 $ hg --debug commit -m'rejects?' -d '3 0' -u 'User Name <user@example.com>'
860 $ hg --debug commit -m'rejects?' -d '3 0' -u 'User Name <user@example.com>'
858 a
861 a
859 overwriting a expanding keywords
862 overwriting a expanding keywords
860 committed changeset 2:85e279d709ffc28c9fdd1b868570985fc3d87082
863 committed changeset 2:85e279d709ffc28c9fdd1b868570985fc3d87082
861 $ hg export -o ../rejecttest.diff tip
864 $ hg export -o ../rejecttest.diff tip
862 $ cd ../Test
865 $ cd ../Test
863 $ hg import ../rejecttest.diff
866 $ hg import ../rejecttest.diff
864 applying ../rejecttest.diff
867 applying ../rejecttest.diff
865 $ cat a b
868 $ cat a b
866 expand $Id: a 4e0994474d25 Thu, 01 Jan 1970 00:00:03 +0000 user $ rejecttest
869 expand $Id: a 4e0994474d25 Thu, 01 Jan 1970 00:00:03 +0000 user $ rejecttest
867 do not process $Id: rejecttest
870 do not process $Id: rejecttest
868 xxx $
871 xxx $
869 $Xinfo: User Name <user@example.com>: rejects? $
872 $Xinfo: User Name <user@example.com>: rejects? $
870 ignore $Id$
873 ignore $Id$
871
874
872 $ hg rollback
875 $ hg rollback
873 repository tip rolled back to revision 2 (undo import)
876 repository tip rolled back to revision 2 (undo import)
874 working directory now based on revision 2
877 working directory now based on revision 2
875 $ hg update --clean
878 $ hg update --clean
876 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
879 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
877
880
878 kwexpand/kwshrink on selected files
881 kwexpand/kwshrink on selected files
879
882
880 $ mkdir x
883 $ mkdir x
881 $ hg copy a x/a
884 $ hg copy a x/a
882 $ hg --verbose kwshrink a
885 $ hg --verbose kwshrink a
883 overwriting a shrinking keywords
886 overwriting a shrinking keywords
884 - sleep required for dirstate.normal() check
887 - sleep required for dirstate.normal() check
885 $ sleep 1
888 $ sleep 1
886 $ hg status a
889 $ hg status a
887 $ hg --verbose kwexpand a
890 $ hg --verbose kwexpand a
888 overwriting a expanding keywords
891 overwriting a expanding keywords
889 $ hg status a
892 $ hg status a
890
893
891 kwexpand x/a should abort
894 kwexpand x/a should abort
892
895
893 $ hg --verbose kwexpand x/a
896 $ hg --verbose kwexpand x/a
894 abort: outstanding uncommitted changes
897 abort: outstanding uncommitted changes
895 [255]
898 [255]
896 $ cd x
899 $ cd x
897 $ hg --debug commit -m xa -d '3 0' -u 'User Name <user@example.com>'
900 $ hg --debug commit -m xa -d '3 0' -u 'User Name <user@example.com>'
898 x/a
901 x/a
899 x/a: copy a:779c764182ce5d43e2b1eb66ce06d7b47bfe342e
902 x/a: copy a:779c764182ce5d43e2b1eb66ce06d7b47bfe342e
900 overwriting x/a expanding keywords
903 overwriting x/a expanding keywords
901 committed changeset 3:b4560182a3f9a358179fd2d835c15e9da379c1e4
904 committed changeset 3:b4560182a3f9a358179fd2d835c15e9da379c1e4
902 $ cat a
905 $ cat a
903 expand $Id: x/a b4560182a3f9 Thu, 01 Jan 1970 00:00:03 +0000 user $
906 expand $Id: x/a b4560182a3f9 Thu, 01 Jan 1970 00:00:03 +0000 user $
904 do not process $Id:
907 do not process $Id:
905 xxx $
908 xxx $
906 $Xinfo: User Name <user@example.com>: xa $
909 $Xinfo: User Name <user@example.com>: xa $
907
910
908 kwshrink a inside directory x
911 kwshrink a inside directory x
909
912
910 $ hg --verbose kwshrink a
913 $ hg --verbose kwshrink a
911 overwriting x/a shrinking keywords
914 overwriting x/a shrinking keywords
912 $ cat a
915 $ cat a
913 expand $Id$
916 expand $Id$
914 do not process $Id:
917 do not process $Id:
915 xxx $
918 xxx $
916 $Xinfo$
919 $Xinfo$
917 $ cd ..
920 $ cd ..
918
921
919 kwexpand nonexistent
922 kwexpand nonexistent
920
923
921 $ hg kwexpand nonexistent
924 $ hg kwexpand nonexistent
922 nonexistent:* (glob)
925 nonexistent:* (glob)
923
926
924
927
925 hg serve
928 hg serve
926 - expand with hgweb file
929 - expand with hgweb file
927 - no expansion with hgweb annotate/changeset/filediff
930 - no expansion with hgweb annotate/changeset/filediff
928 - check errors
931 - check errors
929
932
930 $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
933 $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
931 $ cat hg.pid >> $DAEMON_PIDS
934 $ cat hg.pid >> $DAEMON_PIDS
932 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/file/tip/a/?style=raw'
935 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/file/tip/a/?style=raw'
933 200 Script output follows
936 200 Script output follows
934
937
935 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
938 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
936 do not process $Id:
939 do not process $Id:
937 xxx $
940 xxx $
938 $Xinfo: User Name <user@example.com>: firstline $
941 $Xinfo: User Name <user@example.com>: firstline $
939 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/annotate/tip/a/?style=raw'
942 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/annotate/tip/a/?style=raw'
940 200 Script output follows
943 200 Script output follows
941
944
942
945
943 user@1: expand $Id$
946 user@1: expand $Id$
944 user@1: do not process $Id:
947 user@1: do not process $Id:
945 user@1: xxx $
948 user@1: xxx $
946 user@2: $Xinfo$
949 user@2: $Xinfo$
947
950
948
951
949
952
950
953
951 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/rev/tip/?style=raw'
954 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/rev/tip/?style=raw'
952 200 Script output follows
955 200 Script output follows
953
956
954
957
955 # HG changeset patch
958 # HG changeset patch
956 # User User Name <user@example.com>
959 # User User Name <user@example.com>
957 # Date 3 0
960 # Date 3 0
958 # Node ID b4560182a3f9a358179fd2d835c15e9da379c1e4
961 # Node ID b4560182a3f9a358179fd2d835c15e9da379c1e4
959 # Parent bb948857c743469b22bbf51f7ec8112279ca5d83
962 # Parent bb948857c743469b22bbf51f7ec8112279ca5d83
960 xa
963 xa
961
964
962 diff -r bb948857c743 -r b4560182a3f9 x/a
965 diff -r bb948857c743 -r b4560182a3f9 x/a
963 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
966 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
964 +++ b/x/a Thu Jan 01 00:00:03 1970 +0000
967 +++ b/x/a Thu Jan 01 00:00:03 1970 +0000
965 @@ -0,0 +1,4 @@
968 @@ -0,0 +1,4 @@
966 +expand $Id$
969 +expand $Id$
967 +do not process $Id:
970 +do not process $Id:
968 +xxx $
971 +xxx $
969 +$Xinfo$
972 +$Xinfo$
970
973
971 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/diff/bb948857c743/a?style=raw'
974 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/diff/bb948857c743/a?style=raw'
972 200 Script output follows
975 200 Script output follows
973
976
974
977
975 diff -r ef63ca68695b -r bb948857c743 a
978 diff -r ef63ca68695b -r bb948857c743 a
976 --- a/a Thu Jan 01 00:00:00 1970 +0000
979 --- a/a Thu Jan 01 00:00:00 1970 +0000
977 +++ b/a Thu Jan 01 00:00:02 1970 +0000
980 +++ b/a Thu Jan 01 00:00:02 1970 +0000
978 @@ -1,3 +1,4 @@
981 @@ -1,3 +1,4 @@
979 expand $Id$
982 expand $Id$
980 do not process $Id:
983 do not process $Id:
981 xxx $
984 xxx $
982 +$Xinfo$
985 +$Xinfo$
983
986
984
987
985
988
986
989
987 $ cat errors.log
990 $ cat errors.log
988
991
989 Prepare merge and resolve tests
992 Prepare merge and resolve tests
990
993
991 $ echo '$Id$' > m
994 $ echo '$Id$' > m
992 $ hg add m
995 $ hg add m
993 $ hg commit -m 4kw
996 $ hg commit -m 4kw
994 $ echo foo >> m
997 $ echo foo >> m
995 $ hg commit -m 5foo
998 $ hg commit -m 5foo
996
999
997 simplemerge
1000 simplemerge
998
1001
999 $ hg update 4
1002 $ hg update 4
1000 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1003 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1001 $ echo foo >> m
1004 $ echo foo >> m
1002 $ hg commit -m 6foo
1005 $ hg commit -m 6foo
1003 created new head
1006 created new head
1004 $ hg merge
1007 $ hg merge
1005 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1008 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1006 (branch merge, don't forget to commit)
1009 (branch merge, don't forget to commit)
1007 $ hg commit -m simplemerge
1010 $ hg commit -m simplemerge
1008 $ cat m
1011 $ cat m
1009 $Id: m 27d48ee14f67 Thu, 01 Jan 1970 00:00:00 +0000 test $
1012 $Id: m 27d48ee14f67 Thu, 01 Jan 1970 00:00:00 +0000 test $
1010 foo
1013 foo
1011
1014
1012 conflict: keyword should stay outside conflict zone
1015 conflict: keyword should stay outside conflict zone
1013
1016
1014 $ hg update 4
1017 $ hg update 4
1015 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1018 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1016 $ echo bar >> m
1019 $ echo bar >> m
1017 $ hg commit -m 8bar
1020 $ hg commit -m 8bar
1018 created new head
1021 created new head
1019 $ hg merge
1022 $ hg merge
1020 merging m
1023 merging m
1021 warning: conflicts during merge.
1024 warning: conflicts during merge.
1022 merging m incomplete! (edit conflicts, then use 'hg resolve --mark')
1025 merging m incomplete! (edit conflicts, then use 'hg resolve --mark')
1023 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
1024 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
1025 [1]
1028 [1]
1026 $ cat m
1029 $ cat m
1027 $Id$
1030 $Id$
1028 <<<<<<< local
1031 <<<<<<< local
1029 bar
1032 bar
1030 =======
1033 =======
1031 foo
1034 foo
1032 >>>>>>> other
1035 >>>>>>> other
1033
1036
1034 resolve to local
1037 resolve to local
1035
1038
1036 $ HGMERGE=internal:local hg resolve -a
1039 $ HGMERGE=internal:local hg resolve -a
1037 $ hg commit -m localresolve
1040 $ hg commit -m localresolve
1038 $ cat m
1041 $ cat m
1039 $Id: m 800511b3a22d Thu, 01 Jan 1970 00:00:00 +0000 test $
1042 $Id: m 800511b3a22d Thu, 01 Jan 1970 00:00:00 +0000 test $
1040 bar
1043 bar
1041
1044
1042 Test restricted mode with transplant -b
1045 Test restricted mode with transplant -b
1043
1046
1044 $ hg update 6
1047 $ hg update 6
1045 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1048 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1046 $ hg branch foo
1049 $ hg branch foo
1047 marked working directory as branch foo
1050 marked working directory as branch foo
1048 (branches are permanent and global, did you want a bookmark?)
1051 (branches are permanent and global, did you want a bookmark?)
1049 $ mv a a.bak
1052 $ mv a a.bak
1050 $ echo foobranch > a
1053 $ echo foobranch > a
1051 $ cat a.bak >> a
1054 $ cat a.bak >> a
1052 $ rm a.bak
1055 $ rm a.bak
1053 $ hg commit -m 9foobranch
1056 $ hg commit -m 9foobranch
1054 $ hg update default
1057 $ hg update default
1055 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
1058 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
1056 $ hg -y transplant -b foo tip
1059 $ hg -y transplant -b foo tip
1057 applying 4aa30d025d50
1060 applying 4aa30d025d50
1058 4aa30d025d50 transplanted to e00abbf63521
1061 4aa30d025d50 transplanted to e00abbf63521
1059
1062
1060 Expansion in changeset but not in file
1063 Expansion in changeset but not in file
1061
1064
1062 $ hg tip -p
1065 $ hg tip -p
1063 changeset: 11:e00abbf63521
1066 changeset: 11:e00abbf63521
1064 tag: tip
1067 tag: tip
1065 parent: 9:800511b3a22d
1068 parent: 9:800511b3a22d
1066 user: test
1069 user: test
1067 date: Thu Jan 01 00:00:00 1970 +0000
1070 date: Thu Jan 01 00:00:00 1970 +0000
1068 summary: 9foobranch
1071 summary: 9foobranch
1069
1072
1070 diff -r 800511b3a22d -r e00abbf63521 a
1073 diff -r 800511b3a22d -r e00abbf63521 a
1071 --- a/a Thu Jan 01 00:00:00 1970 +0000
1074 --- a/a Thu Jan 01 00:00:00 1970 +0000
1072 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1075 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1073 @@ -1,3 +1,4 @@
1076 @@ -1,3 +1,4 @@
1074 +foobranch
1077 +foobranch
1075 expand $Id$
1078 expand $Id$
1076 do not process $Id:
1079 do not process $Id:
1077 xxx $
1080 xxx $
1078
1081
1079 $ head -n 2 a
1082 $ head -n 2 a
1080 foobranch
1083 foobranch
1081 expand $Id: a e00abbf63521 Thu, 01 Jan 1970 00:00:00 +0000 test $
1084 expand $Id: a e00abbf63521 Thu, 01 Jan 1970 00:00:00 +0000 test $
1082
1085
1083 Turn off expansion
1086 Turn off expansion
1084
1087
1085 $ hg -q rollback
1088 $ hg -q rollback
1086 $ hg -q update -C
1089 $ hg -q update -C
1087
1090
1088 kwshrink with unknown file u
1091 kwshrink with unknown file u
1089
1092
1090 $ cp a u
1093 $ cp a u
1091 $ hg --verbose kwshrink
1094 $ hg --verbose kwshrink
1092 overwriting a shrinking keywords
1095 overwriting a shrinking keywords
1093 overwriting m shrinking keywords
1096 overwriting m shrinking keywords
1094 overwriting x/a shrinking keywords
1097 overwriting x/a shrinking keywords
1095
1098
1096 Keywords shrunk in working directory, but not yet disabled
1099 Keywords shrunk in working directory, but not yet disabled
1097 - cat shows unexpanded keywords
1100 - cat shows unexpanded keywords
1098 - hg cat shows expanded keywords
1101 - hg cat shows expanded keywords
1099
1102
1100 $ cat a b
1103 $ cat a b
1101 expand $Id$
1104 expand $Id$
1102 do not process $Id:
1105 do not process $Id:
1103 xxx $
1106 xxx $
1104 $Xinfo$
1107 $Xinfo$
1105 ignore $Id$
1108 ignore $Id$
1106 $ hg cat sym a b && echo
1109 $ hg cat sym a b && echo
1107 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
1110 expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $
1108 do not process $Id:
1111 do not process $Id:
1109 xxx $
1112 xxx $
1110 $Xinfo: User Name <user@example.com>: firstline $
1113 $Xinfo: User Name <user@example.com>: firstline $
1111 ignore $Id$
1114 ignore $Id$
1112 a
1115 a
1113
1116
1114 Now disable keyword expansion
1117 Now disable keyword expansion
1115
1118
1116 $ rm "$HGRCPATH"
1119 $ rm "$HGRCPATH"
1117 $ cat a b
1120 $ cat a b
1118 expand $Id$
1121 expand $Id$
1119 do not process $Id:
1122 do not process $Id:
1120 xxx $
1123 xxx $
1121 $Xinfo$
1124 $Xinfo$
1122 ignore $Id$
1125 ignore $Id$
1123 $ hg cat sym a b && echo
1126 $ hg cat sym a b && echo
1124 expand $Id$
1127 expand $Id$
1125 do not process $Id:
1128 do not process $Id:
1126 xxx $
1129 xxx $
1127 $Xinfo$
1130 $Xinfo$
1128 ignore $Id$
1131 ignore $Id$
1129 a
1132 a
1130
1133
1131 $ cd ..
1134 $ cd ..
@@ -1,150 +1,153 b''
1 $ "$TESTDIR/hghave" serve || exit 80
1 $ "$TESTDIR/hghave" serve || exit 80
2
2
3 hide outer repo
4 $ hg init
5
3 $ echo "[extensions]" >> $HGRCPATH
6 $ echo "[extensions]" >> $HGRCPATH
4 $ echo "mq=" >> $HGRCPATH
7 $ echo "mq=" >> $HGRCPATH
5 $ mkdir webdir
8 $ mkdir webdir
6 $ cd webdir
9 $ cd webdir
7 $ hg init a
10 $ hg init a
8 $ hg --cwd a qinit -c
11 $ hg --cwd a qinit -c
9 $ echo a > a/a
12 $ echo a > a/a
10 $ hg --cwd a ci -A -m a
13 $ hg --cwd a ci -A -m a
11 adding a
14 adding a
12 $ echo b > a/b
15 $ echo b > a/b
13 $ hg --cwd a addremove
16 $ hg --cwd a addremove
14 adding b
17 adding b
15 $ hg --cwd a qnew -f b.patch
18 $ hg --cwd a qnew -f b.patch
16 $ hg --cwd a qcommit -m b.patch
19 $ hg --cwd a qcommit -m b.patch
17 $ hg --cwd a log --template "{desc}\n"
20 $ hg --cwd a log --template "{desc}\n"
18 [mq]: b.patch
21 [mq]: b.patch
19 a
22 a
20 $ hg --cwd a/.hg/patches log --template "{desc}\n"
23 $ hg --cwd a/.hg/patches log --template "{desc}\n"
21 b.patch
24 b.patch
22 $ root=`pwd`
25 $ root=`pwd`
23 $ cd ..
26 $ cd ..
24
27
25 test with recursive collection
28 test with recursive collection
26
29
27 $ cat > collections.conf <<EOF
30 $ cat > collections.conf <<EOF
28 > [paths]
31 > [paths]
29 > /=$root/**
32 > /=$root/**
30 > EOF
33 > EOF
31 $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf collections.conf \
34 $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf collections.conf \
32 > -A access-paths.log -E error-paths-1.log
35 > -A access-paths.log -E error-paths-1.log
33 $ cat hg.pid >> $DAEMON_PIDS
36 $ cat hg.pid >> $DAEMON_PIDS
34 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
37 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT '/?style=raw'
35 200 Script output follows
38 200 Script output follows
36
39
37
40
38 /a/
41 /a/
39 /a/.hg/patches/
42 /a/.hg/patches/
40
43
41 $ hg qclone http://localhost:$HGPORT/a b
44 $ hg qclone http://localhost:$HGPORT/a b
42 requesting all changes
45 requesting all changes
43 adding changesets
46 adding changesets
44 adding manifests
47 adding manifests
45 adding file changes
48 adding file changes
46 added 2 changesets with 2 changes to 2 files
49 added 2 changesets with 2 changes to 2 files
47 requesting all changes
50 requesting all changes
48 adding changesets
51 adding changesets
49 adding manifests
52 adding manifests
50 adding file changes
53 adding file changes
51 added 1 changesets with 3 changes to 3 files
54 added 1 changesets with 3 changes to 3 files
52 updating to branch default
55 updating to branch default
53 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
56 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
54 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
57 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
55 $ hg --cwd b log --template "{desc}\n"
58 $ hg --cwd b log --template "{desc}\n"
56 a
59 a
57 $ hg --cwd b qpush -a
60 $ hg --cwd b qpush -a
58 applying b.patch
61 applying b.patch
59 now at: b.patch
62 now at: b.patch
60 $ hg --cwd b log --template "{desc}\n"
63 $ hg --cwd b log --template "{desc}\n"
61 imported patch b.patch
64 imported patch b.patch
62 a
65 a
63
66
64 test with normal collection
67 test with normal collection
65
68
66 $ cat > collections1.conf <<EOF
69 $ cat > collections1.conf <<EOF
67 > [paths]
70 > [paths]
68 > /=$root/*
71 > /=$root/*
69 > EOF
72 > EOF
70 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf collections1.conf \
73 $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf collections1.conf \
71 > -A access-paths.log -E error-paths-1.log
74 > -A access-paths.log -E error-paths-1.log
72 $ cat hg.pid >> $DAEMON_PIDS
75 $ cat hg.pid >> $DAEMON_PIDS
73 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
76 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT1 '/?style=raw'
74 200 Script output follows
77 200 Script output follows
75
78
76
79
77 /a/
80 /a/
78 /a/.hg/patches/
81 /a/.hg/patches/
79
82
80 $ hg qclone http://localhost:$HGPORT1/a c
83 $ hg qclone http://localhost:$HGPORT1/a c
81 requesting all changes
84 requesting all changes
82 adding changesets
85 adding changesets
83 adding manifests
86 adding manifests
84 adding file changes
87 adding file changes
85 added 2 changesets with 2 changes to 2 files
88 added 2 changesets with 2 changes to 2 files
86 requesting all changes
89 requesting all changes
87 adding changesets
90 adding changesets
88 adding manifests
91 adding manifests
89 adding file changes
92 adding file changes
90 added 1 changesets with 3 changes to 3 files
93 added 1 changesets with 3 changes to 3 files
91 updating to branch default
94 updating to branch default
92 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
95 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
93 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
96 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
94 $ hg --cwd c log --template "{desc}\n"
97 $ hg --cwd c log --template "{desc}\n"
95 a
98 a
96 $ hg --cwd c qpush -a
99 $ hg --cwd c qpush -a
97 applying b.patch
100 applying b.patch
98 now at: b.patch
101 now at: b.patch
99 $ hg --cwd c log --template "{desc}\n"
102 $ hg --cwd c log --template "{desc}\n"
100 imported patch b.patch
103 imported patch b.patch
101 a
104 a
102
105
103 test with old-style collection
106 test with old-style collection
104
107
105 $ cat > collections2.conf <<EOF
108 $ cat > collections2.conf <<EOF
106 > [collections]
109 > [collections]
107 > $root=$root
110 > $root=$root
108 > EOF
111 > EOF
109 $ hg serve -p $HGPORT2 -d --pid-file=hg.pid --webdir-conf collections2.conf \
112 $ hg serve -p $HGPORT2 -d --pid-file=hg.pid --webdir-conf collections2.conf \
110 > -A access-paths.log -E error-paths-1.log
113 > -A access-paths.log -E error-paths-1.log
111 $ cat hg.pid >> $DAEMON_PIDS
114 $ cat hg.pid >> $DAEMON_PIDS
112 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/?style=raw'
115 $ "$TESTDIR/get-with-headers.py" localhost:$HGPORT2 '/?style=raw'
113 200 Script output follows
116 200 Script output follows
114
117
115
118
116 /a/
119 /a/
117 /a/.hg/patches/
120 /a/.hg/patches/
118
121
119 $ hg qclone http://localhost:$HGPORT2/a d
122 $ hg qclone http://localhost:$HGPORT2/a d
120 requesting all changes
123 requesting all changes
121 adding changesets
124 adding changesets
122 adding manifests
125 adding manifests
123 adding file changes
126 adding file changes
124 added 2 changesets with 2 changes to 2 files
127 added 2 changesets with 2 changes to 2 files
125 requesting all changes
128 requesting all changes
126 adding changesets
129 adding changesets
127 adding manifests
130 adding manifests
128 adding file changes
131 adding file changes
129 added 1 changesets with 3 changes to 3 files
132 added 1 changesets with 3 changes to 3 files
130 updating to branch default
133 updating to branch default
131 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
134 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
132 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
135 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
133 $ hg --cwd d log --template "{desc}\n"
136 $ hg --cwd d log --template "{desc}\n"
134 a
137 a
135 $ hg --cwd d qpush -a
138 $ hg --cwd d qpush -a
136 applying b.patch
139 applying b.patch
137 now at: b.patch
140 now at: b.patch
138 $ hg --cwd d log --template "{desc}\n"
141 $ hg --cwd d log --template "{desc}\n"
139 imported patch b.patch
142 imported patch b.patch
140 a
143 a
141
144
142 test --mq works and uses correct repository config
145 test --mq works and uses correct repository config
143
146
144 $ hg --cwd d outgoing --mq
147 $ hg --cwd d outgoing --mq
145 comparing with http://localhost:$HGPORT2/a/.hg/patches
148 comparing with http://localhost:$HGPORT2/a/.hg/patches
146 searching for changes
149 searching for changes
147 no changes found
150 no changes found
148 [1]
151 [1]
149 $ hg --cwd d log --mq --template '{rev} {desc|firstline}\n'
152 $ hg --cwd d log --mq --template '{rev} {desc|firstline}\n'
150 0 b.patch
153 0 b.patch
@@ -1,1548 +1,1552 b''
1 $ checkundo()
1 $ checkundo()
2 > {
2 > {
3 > if [ -f .hg/store/undo ]; then
3 > if [ -f .hg/store/undo ]; then
4 > echo ".hg/store/undo still exists after $1"
4 > echo ".hg/store/undo still exists after $1"
5 > fi
5 > fi
6 > }
6 > }
7
7
8 $ echo "[extensions]" >> $HGRCPATH
8 $ echo "[extensions]" >> $HGRCPATH
9 $ echo "mq=" >> $HGRCPATH
9 $ echo "mq=" >> $HGRCPATH
10
10
11 $ echo "[mq]" >> $HGRCPATH
11 $ echo "[mq]" >> $HGRCPATH
12 $ echo "plain=true" >> $HGRCPATH
12 $ echo "plain=true" >> $HGRCPATH
13
13
14
14
15 help
15 help
16
16
17 $ hg help mq
17 $ hg help mq
18 mq extension - manage a stack of patches
18 mq extension - manage a stack of patches
19
19
20 This extension lets you work with a stack of patches in a Mercurial
20 This extension lets you work with a stack of patches in a Mercurial
21 repository. It manages two stacks of patches - all known patches, and applied
21 repository. It manages two stacks of patches - all known patches, and applied
22 patches (subset of known patches).
22 patches (subset of known patches).
23
23
24 Known patches are represented as patch files in the .hg/patches directory.
24 Known patches are represented as patch files in the .hg/patches directory.
25 Applied patches are both patch files and changesets.
25 Applied patches are both patch files and changesets.
26
26
27 Common tasks (use "hg help command" for more details):
27 Common tasks (use "hg help command" for more details):
28
28
29 create new patch qnew
29 create new patch qnew
30 import existing patch qimport
30 import existing patch qimport
31
31
32 print patch series qseries
32 print patch series qseries
33 print applied patches qapplied
33 print applied patches qapplied
34
34
35 add known patch to applied stack qpush
35 add known patch to applied stack qpush
36 remove patch from applied stack qpop
36 remove patch from applied stack qpop
37 refresh contents of top applied patch qrefresh
37 refresh contents of top applied patch qrefresh
38
38
39 By default, mq will automatically use git patches when required to avoid
39 By default, mq will automatically use git patches when required to avoid
40 losing file mode changes, copy records, binary files or empty files creations
40 losing file mode changes, copy records, binary files or empty files creations
41 or deletions. This behaviour can be configured with:
41 or deletions. This behaviour can be configured with:
42
42
43 [mq]
43 [mq]
44 git = auto/keep/yes/no
44 git = auto/keep/yes/no
45
45
46 If set to 'keep', mq will obey the [diff] section configuration while
46 If set to 'keep', mq will obey the [diff] section configuration while
47 preserving existing git patches upon qrefresh. If set to 'yes' or 'no', mq
47 preserving existing git patches upon qrefresh. If set to 'yes' or 'no', mq
48 will override the [diff] section and always generate git or regular patches,
48 will override the [diff] section and always generate git or regular patches,
49 possibly losing data in the second case.
49 possibly losing data in the second case.
50
50
51 It may be desirable for mq changesets to be kept in the secret phase (see "hg
51 It may be desirable for mq changesets to be kept in the secret phase (see "hg
52 help phases"), which can be enabled with the following setting:
52 help phases"), which can be enabled with the following setting:
53
53
54 [mq]
54 [mq]
55 secret = True
55 secret = True
56
56
57 You will by default be managing a patch queue named "patches". You can create
57 You will by default be managing a patch queue named "patches". You can create
58 other, independent patch queues with the "hg qqueue" command.
58 other, independent patch queues with the "hg qqueue" command.
59
59
60 If the working directory contains uncommitted files, qpush, qpop and qgoto
60 If the working directory contains uncommitted files, qpush, qpop and qgoto
61 abort immediately. If -f/--force is used, the changes are discarded. Setting:
61 abort immediately. If -f/--force is used, the changes are discarded. Setting:
62
62
63 [mq]
63 [mq]
64 keepchanges = True
64 keepchanges = True
65
65
66 make them behave as if --keep-changes were passed, and non-conflicting local
66 make them behave as if --keep-changes were passed, and non-conflicting local
67 changes will be tolerated and preserved. If incompatible options such as
67 changes will be tolerated and preserved. If incompatible options such as
68 -f/--force or --exact are passed, this setting is ignored.
68 -f/--force or --exact are passed, this setting is ignored.
69
69
70 list of commands:
70 list of commands:
71
71
72 qapplied print the patches already applied
72 qapplied print the patches already applied
73 qclone clone main and patch repository at same time
73 qclone clone main and patch repository at same time
74 qdelete remove patches from queue
74 qdelete remove patches from queue
75 qdiff diff of the current patch and subsequent modifications
75 qdiff diff of the current patch and subsequent modifications
76 qfinish move applied patches into repository history
76 qfinish move applied patches into repository history
77 qfold fold the named patches into the current patch
77 qfold fold the named patches into the current patch
78 qgoto push or pop patches until named patch is at top of stack
78 qgoto push or pop patches until named patch is at top of stack
79 qguard set or print guards for a patch
79 qguard set or print guards for a patch
80 qheader print the header of the topmost or specified patch
80 qheader print the header of the topmost or specified patch
81 qimport import a patch or existing changeset
81 qimport import a patch or existing changeset
82 qnew create a new patch
82 qnew create a new patch
83 qnext print the name of the next pushable patch
83 qnext print the name of the next pushable patch
84 qpop pop the current patch off the stack
84 qpop pop the current patch off the stack
85 qprev print the name of the preceding applied patch
85 qprev print the name of the preceding applied patch
86 qpush push the next patch onto the stack
86 qpush push the next patch onto the stack
87 qqueue manage multiple patch queues
87 qqueue manage multiple patch queues
88 qrefresh update the current patch
88 qrefresh update the current patch
89 qrename rename a patch
89 qrename rename a patch
90 qselect set or print guarded patches to push
90 qselect set or print guarded patches to push
91 qseries print the entire series file
91 qseries print the entire series file
92 qtop print the name of the current patch
92 qtop print the name of the current patch
93 qunapplied print the patches not yet applied
93 qunapplied print the patches not yet applied
94 strip strip changesets and all their descendants from the repository
94 strip strip changesets and all their descendants from the repository
95
95
96 use "hg -v help mq" to show builtin aliases and global options
96 use "hg -v help mq" to show builtin aliases and global options
97
97
98 $ hg init a
98 $ hg init a
99 $ cd a
99 $ cd a
100 $ echo a > a
100 $ echo a > a
101 $ hg ci -Ama
101 $ hg ci -Ama
102 adding a
102 adding a
103
103
104 $ hg clone . ../k
104 $ hg clone . ../k
105 updating to branch default
105 updating to branch default
106 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
106 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
107
107
108 $ mkdir b
108 $ mkdir b
109 $ echo z > b/z
109 $ echo z > b/z
110 $ hg ci -Ama
110 $ hg ci -Ama
111 adding b/z
111 adding b/z
112
112
113
113
114 qinit
114 qinit
115
115
116 $ hg qinit
116 $ hg qinit
117
117
118 $ cd ..
118 $ cd ..
119 $ hg init b
119 $ hg init b
120
120
121
121
122 -R qinit
122 -R qinit
123
123
124 $ hg -R b qinit
124 $ hg -R b qinit
125
125
126 $ hg init c
126 $ hg init c
127
127
128
128
129 qinit -c
129 qinit -c
130
130
131 $ hg --cwd c qinit -c
131 $ hg --cwd c qinit -c
132 $ hg -R c/.hg/patches st
132 $ hg -R c/.hg/patches st
133 A .hgignore
133 A .hgignore
134 A series
134 A series
135
135
136
136
137 qinit; qinit -c
137 qinit; qinit -c
138
138
139 $ hg init d
139 $ hg init d
140 $ cd d
140 $ cd d
141 $ hg qinit
141 $ hg qinit
142 $ hg qinit -c
142 $ hg qinit -c
143
143
144 qinit -c should create both files if they don't exist
144 qinit -c should create both files if they don't exist
145
145
146 $ cat .hg/patches/.hgignore
146 $ cat .hg/patches/.hgignore
147 ^\.hg
147 ^\.hg
148 ^\.mq
148 ^\.mq
149 syntax: glob
149 syntax: glob
150 status
150 status
151 guards
151 guards
152 $ cat .hg/patches/series
152 $ cat .hg/patches/series
153 $ hg qinit -c
153 $ hg qinit -c
154 abort: repository $TESTTMP/d/.hg/patches already exists! (glob)
154 abort: repository $TESTTMP/d/.hg/patches already exists! (glob)
155 [255]
155 [255]
156 $ cd ..
156 $ cd ..
157
157
158 $ echo '% qinit; <stuff>; qinit -c'
158 $ echo '% qinit; <stuff>; qinit -c'
159 % qinit; <stuff>; qinit -c
159 % qinit; <stuff>; qinit -c
160 $ hg init e
160 $ hg init e
161 $ cd e
161 $ cd e
162 $ hg qnew A
162 $ hg qnew A
163 $ checkundo qnew
163 $ checkundo qnew
164 $ echo foo > foo
164 $ echo foo > foo
165 $ hg phase -r qbase
165 $ hg phase -r qbase
166 0: draft
166 0: draft
167 $ hg add foo
167 $ hg add foo
168 $ hg qrefresh
168 $ hg qrefresh
169 $ hg phase -r qbase
169 $ hg phase -r qbase
170 0: draft
170 0: draft
171 $ hg qnew B
171 $ hg qnew B
172 $ echo >> foo
172 $ echo >> foo
173 $ hg qrefresh
173 $ hg qrefresh
174 $ echo status >> .hg/patches/.hgignore
174 $ echo status >> .hg/patches/.hgignore
175 $ echo bleh >> .hg/patches/.hgignore
175 $ echo bleh >> .hg/patches/.hgignore
176 $ hg qinit -c
176 $ hg qinit -c
177 adding .hg/patches/A (glob)
177 adding .hg/patches/A (glob)
178 adding .hg/patches/B (glob)
178 adding .hg/patches/B (glob)
179 $ hg -R .hg/patches status
179 $ hg -R .hg/patches status
180 A .hgignore
180 A .hgignore
181 A A
181 A A
182 A B
182 A B
183 A series
183 A series
184
184
185 qinit -c shouldn't touch these files if they already exist
185 qinit -c shouldn't touch these files if they already exist
186
186
187 $ cat .hg/patches/.hgignore
187 $ cat .hg/patches/.hgignore
188 status
188 status
189 bleh
189 bleh
190 $ cat .hg/patches/series
190 $ cat .hg/patches/series
191 A
191 A
192 B
192 B
193
193
194 add an untracked file
194 add an untracked file
195
195
196 $ echo >> .hg/patches/flaf
196 $ echo >> .hg/patches/flaf
197
197
198 status --mq with color (issue2096)
198 status --mq with color (issue2096)
199
199
200 $ hg status --mq --config extensions.color= --config color.mode=ansi --color=always
200 $ hg status --mq --config extensions.color= --config color.mode=ansi --color=always
201 \x1b[0;32;1mA .hgignore\x1b[0m (esc)
201 \x1b[0;32;1mA .hgignore\x1b[0m (esc)
202 \x1b[0;32;1mA A\x1b[0m (esc)
202 \x1b[0;32;1mA A\x1b[0m (esc)
203 \x1b[0;32;1mA B\x1b[0m (esc)
203 \x1b[0;32;1mA B\x1b[0m (esc)
204 \x1b[0;32;1mA series\x1b[0m (esc)
204 \x1b[0;32;1mA series\x1b[0m (esc)
205 \x1b[0;35;1;4m? flaf\x1b[0m (esc)
205 \x1b[0;35;1;4m? flaf\x1b[0m (esc)
206
206
207 try the --mq option on a command provided by an extension
207 try the --mq option on a command provided by an extension
208
208
209 $ hg purge --mq --verbose --config extensions.purge=
209 $ hg purge --mq --verbose --config extensions.purge=
210 removing file flaf
210 removing file flaf
211
211
212 $ cd ..
212 $ cd ..
213
213
214 #if no-outer-repo
215
214 init --mq without repo
216 init --mq without repo
215
217
216 $ mkdir f
218 $ mkdir f
217 $ cd f
219 $ cd f
218 $ hg init --mq
220 $ hg init --mq
219 abort: there is no Mercurial repository here (.hg not found)
221 abort: there is no Mercurial repository here (.hg not found)
220 [255]
222 [255]
221 $ cd ..
223 $ cd ..
222
224
225 #endif
226
223 init --mq with repo path
227 init --mq with repo path
224
228
225 $ hg init g
229 $ hg init g
226 $ hg init --mq g
230 $ hg init --mq g
227 $ test -d g/.hg/patches/.hg
231 $ test -d g/.hg/patches/.hg
228
232
229 init --mq with nonexistent directory
233 init --mq with nonexistent directory
230
234
231 $ hg init --mq nonexistentdir
235 $ hg init --mq nonexistentdir
232 abort: repository nonexistentdir not found!
236 abort: repository nonexistentdir not found!
233 [255]
237 [255]
234
238
235
239
236 init --mq with bundle (non "local")
240 init --mq with bundle (non "local")
237
241
238 $ hg -R a bundle --all a.bundle >/dev/null
242 $ hg -R a bundle --all a.bundle >/dev/null
239 $ hg init --mq a.bundle
243 $ hg init --mq a.bundle
240 abort: only a local queue repository may be initialized
244 abort: only a local queue repository may be initialized
241 [255]
245 [255]
242
246
243 $ cd a
247 $ cd a
244
248
245 $ hg qnew -m 'foo bar' test.patch
249 $ hg qnew -m 'foo bar' test.patch
246
250
247 $ echo '# comment' > .hg/patches/series.tmp
251 $ echo '# comment' > .hg/patches/series.tmp
248 $ echo >> .hg/patches/series.tmp # empty line
252 $ echo >> .hg/patches/series.tmp # empty line
249 $ cat .hg/patches/series >> .hg/patches/series.tmp
253 $ cat .hg/patches/series >> .hg/patches/series.tmp
250 $ mv .hg/patches/series.tmp .hg/patches/series
254 $ mv .hg/patches/series.tmp .hg/patches/series
251
255
252
256
253 qrefresh
257 qrefresh
254
258
255 $ echo a >> a
259 $ echo a >> a
256 $ hg qrefresh
260 $ hg qrefresh
257 $ cat .hg/patches/test.patch
261 $ cat .hg/patches/test.patch
258 foo bar
262 foo bar
259
263
260 diff -r [a-f0-9]* a (re)
264 diff -r [a-f0-9]* a (re)
261 --- a/a\t(?P<date>.*) (re)
265 --- a/a\t(?P<date>.*) (re)
262 \+\+\+ b/a\t(?P<date2>.*) (re)
266 \+\+\+ b/a\t(?P<date2>.*) (re)
263 @@ -1,1 +1,2 @@
267 @@ -1,1 +1,2 @@
264 a
268 a
265 +a
269 +a
266
270
267 empty qrefresh
271 empty qrefresh
268
272
269 $ hg qrefresh -X a
273 $ hg qrefresh -X a
270
274
271 revision:
275 revision:
272
276
273 $ hg diff -r -2 -r -1
277 $ hg diff -r -2 -r -1
274
278
275 patch:
279 patch:
276
280
277 $ cat .hg/patches/test.patch
281 $ cat .hg/patches/test.patch
278 foo bar
282 foo bar
279
283
280
284
281 working dir diff:
285 working dir diff:
282
286
283 $ hg diff --nodates -q
287 $ hg diff --nodates -q
284 --- a/a
288 --- a/a
285 +++ b/a
289 +++ b/a
286 @@ -1,1 +1,2 @@
290 @@ -1,1 +1,2 @@
287 a
291 a
288 +a
292 +a
289
293
290 restore things
294 restore things
291
295
292 $ hg qrefresh
296 $ hg qrefresh
293 $ checkundo qrefresh
297 $ checkundo qrefresh
294
298
295
299
296 qpop
300 qpop
297
301
298 $ hg qpop
302 $ hg qpop
299 popping test.patch
303 popping test.patch
300 patch queue now empty
304 patch queue now empty
301 $ checkundo qpop
305 $ checkundo qpop
302
306
303
307
304 qpush with dump of tag cache
308 qpush with dump of tag cache
305 Dump the tag cache to ensure that it has exactly one head after qpush.
309 Dump the tag cache to ensure that it has exactly one head after qpush.
306
310
307 $ rm -f .hg/cache/tags
311 $ rm -f .hg/cache/tags
308 $ hg tags > /dev/null
312 $ hg tags > /dev/null
309
313
310 .hg/cache/tags (pre qpush):
314 .hg/cache/tags (pre qpush):
311
315
312 $ cat .hg/cache/tags
316 $ cat .hg/cache/tags
313 1 [\da-f]{40} (re)
317 1 [\da-f]{40} (re)
314
318
315 $ hg qpush
319 $ hg qpush
316 applying test.patch
320 applying test.patch
317 now at: test.patch
321 now at: test.patch
318 $ hg phase -r qbase
322 $ hg phase -r qbase
319 2: draft
323 2: draft
320 $ hg tags > /dev/null
324 $ hg tags > /dev/null
321
325
322 .hg/cache/tags (post qpush):
326 .hg/cache/tags (post qpush):
323
327
324 $ cat .hg/cache/tags
328 $ cat .hg/cache/tags
325 2 [\da-f]{40} (re)
329 2 [\da-f]{40} (re)
326
330
327 $ checkundo qpush
331 $ checkundo qpush
328 $ cd ..
332 $ cd ..
329
333
330
334
331 pop/push outside repo
335 pop/push outside repo
332 $ hg -R a qpop
336 $ hg -R a qpop
333 popping test.patch
337 popping test.patch
334 patch queue now empty
338 patch queue now empty
335 $ hg -R a qpush
339 $ hg -R a qpush
336 applying test.patch
340 applying test.patch
337 now at: test.patch
341 now at: test.patch
338
342
339 $ cd a
343 $ cd a
340 $ hg qnew test2.patch
344 $ hg qnew test2.patch
341
345
342 qrefresh in subdir
346 qrefresh in subdir
343
347
344 $ cd b
348 $ cd b
345 $ echo a > a
349 $ echo a > a
346 $ hg add a
350 $ hg add a
347 $ hg qrefresh
351 $ hg qrefresh
348
352
349 pop/push -a in subdir
353 pop/push -a in subdir
350
354
351 $ hg qpop -a
355 $ hg qpop -a
352 popping test2.patch
356 popping test2.patch
353 popping test.patch
357 popping test.patch
354 patch queue now empty
358 patch queue now empty
355 $ hg --traceback qpush -a
359 $ hg --traceback qpush -a
356 applying test.patch
360 applying test.patch
357 applying test2.patch
361 applying test2.patch
358 now at: test2.patch
362 now at: test2.patch
359
363
360
364
361 setting columns & formatted tests truncating (issue1912)
365 setting columns & formatted tests truncating (issue1912)
362
366
363 $ COLUMNS=4 hg qseries --config ui.formatted=true
367 $ COLUMNS=4 hg qseries --config ui.formatted=true
364 test.patch
368 test.patch
365 test2.patch
369 test2.patch
366 $ COLUMNS=20 hg qseries --config ui.formatted=true -vs
370 $ COLUMNS=20 hg qseries --config ui.formatted=true -vs
367 0 A test.patch: f...
371 0 A test.patch: f...
368 1 A test2.patch:
372 1 A test2.patch:
369 $ hg qpop
373 $ hg qpop
370 popping test2.patch
374 popping test2.patch
371 now at: test.patch
375 now at: test.patch
372 $ hg qseries -vs
376 $ hg qseries -vs
373 0 A test.patch: foo bar
377 0 A test.patch: foo bar
374 1 U test2.patch:
378 1 U test2.patch:
375 $ hg sum | grep mq
379 $ hg sum | grep mq
376 mq: 1 applied, 1 unapplied
380 mq: 1 applied, 1 unapplied
377 $ hg qpush
381 $ hg qpush
378 applying test2.patch
382 applying test2.patch
379 now at: test2.patch
383 now at: test2.patch
380 $ hg sum | grep mq
384 $ hg sum | grep mq
381 mq: 2 applied
385 mq: 2 applied
382 $ hg qapplied
386 $ hg qapplied
383 test.patch
387 test.patch
384 test2.patch
388 test2.patch
385 $ hg qtop
389 $ hg qtop
386 test2.patch
390 test2.patch
387
391
388
392
389 prev
393 prev
390
394
391 $ hg qapp -1
395 $ hg qapp -1
392 test.patch
396 test.patch
393
397
394 next
398 next
395
399
396 $ hg qunapp -1
400 $ hg qunapp -1
397 all patches applied
401 all patches applied
398 [1]
402 [1]
399
403
400 $ hg qpop
404 $ hg qpop
401 popping test2.patch
405 popping test2.patch
402 now at: test.patch
406 now at: test.patch
403
407
404 commit should fail
408 commit should fail
405
409
406 $ hg commit
410 $ hg commit
407 abort: cannot commit over an applied mq patch
411 abort: cannot commit over an applied mq patch
408 [255]
412 [255]
409
413
410 push should fail if draft
414 push should fail if draft
411
415
412 $ hg push ../../k
416 $ hg push ../../k
413 pushing to ../../k
417 pushing to ../../k
414 abort: source has mq patches applied
418 abort: source has mq patches applied
415 [255]
419 [255]
416
420
417
421
418 import should fail
422 import should fail
419
423
420 $ hg st .
424 $ hg st .
421 $ echo foo >> ../a
425 $ echo foo >> ../a
422 $ hg diff > ../../import.diff
426 $ hg diff > ../../import.diff
423 $ hg revert --no-backup ../a
427 $ hg revert --no-backup ../a
424 $ hg import ../../import.diff
428 $ hg import ../../import.diff
425 abort: cannot import over an applied patch
429 abort: cannot import over an applied patch
426 [255]
430 [255]
427 $ hg st
431 $ hg st
428
432
429 import --no-commit should succeed
433 import --no-commit should succeed
430
434
431 $ hg import --no-commit ../../import.diff
435 $ hg import --no-commit ../../import.diff
432 applying ../../import.diff
436 applying ../../import.diff
433 $ hg st
437 $ hg st
434 M a
438 M a
435 $ hg revert --no-backup ../a
439 $ hg revert --no-backup ../a
436
440
437
441
438 qunapplied
442 qunapplied
439
443
440 $ hg qunapplied
444 $ hg qunapplied
441 test2.patch
445 test2.patch
442
446
443
447
444 qpush/qpop with index
448 qpush/qpop with index
445
449
446 $ hg qnew test1b.patch
450 $ hg qnew test1b.patch
447 $ echo 1b > 1b
451 $ echo 1b > 1b
448 $ hg add 1b
452 $ hg add 1b
449 $ hg qrefresh
453 $ hg qrefresh
450 $ hg qpush 2
454 $ hg qpush 2
451 applying test2.patch
455 applying test2.patch
452 now at: test2.patch
456 now at: test2.patch
453 $ hg qpop 0
457 $ hg qpop 0
454 popping test2.patch
458 popping test2.patch
455 popping test1b.patch
459 popping test1b.patch
456 now at: test.patch
460 now at: test.patch
457 $ hg qpush test.patch+1
461 $ hg qpush test.patch+1
458 applying test1b.patch
462 applying test1b.patch
459 now at: test1b.patch
463 now at: test1b.patch
460 $ hg qpush test.patch+2
464 $ hg qpush test.patch+2
461 applying test2.patch
465 applying test2.patch
462 now at: test2.patch
466 now at: test2.patch
463 $ hg qpop test2.patch-1
467 $ hg qpop test2.patch-1
464 popping test2.patch
468 popping test2.patch
465 now at: test1b.patch
469 now at: test1b.patch
466 $ hg qpop test2.patch-2
470 $ hg qpop test2.patch-2
467 popping test1b.patch
471 popping test1b.patch
468 now at: test.patch
472 now at: test.patch
469 $ hg qpush test1b.patch+1
473 $ hg qpush test1b.patch+1
470 applying test1b.patch
474 applying test1b.patch
471 applying test2.patch
475 applying test2.patch
472 now at: test2.patch
476 now at: test2.patch
473
477
474
478
475 qpush --move
479 qpush --move
476
480
477 $ hg qpop -a
481 $ hg qpop -a
478 popping test2.patch
482 popping test2.patch
479 popping test1b.patch
483 popping test1b.patch
480 popping test.patch
484 popping test.patch
481 patch queue now empty
485 patch queue now empty
482 $ hg qguard test1b.patch -- -negguard
486 $ hg qguard test1b.patch -- -negguard
483 $ hg qguard test2.patch -- +posguard
487 $ hg qguard test2.patch -- +posguard
484 $ hg qpush --move test2.patch # can't move guarded patch
488 $ hg qpush --move test2.patch # can't move guarded patch
485 cannot push 'test2.patch' - guarded by '+posguard'
489 cannot push 'test2.patch' - guarded by '+posguard'
486 [1]
490 [1]
487 $ hg qselect posguard
491 $ hg qselect posguard
488 number of unguarded, unapplied patches has changed from 2 to 3
492 number of unguarded, unapplied patches has changed from 2 to 3
489 $ hg qpush --move test2.patch # move to front
493 $ hg qpush --move test2.patch # move to front
490 applying test2.patch
494 applying test2.patch
491 now at: test2.patch
495 now at: test2.patch
492 $ hg qpush --move test1b.patch # negative guard unselected
496 $ hg qpush --move test1b.patch # negative guard unselected
493 applying test1b.patch
497 applying test1b.patch
494 now at: test1b.patch
498 now at: test1b.patch
495 $ hg qpush --move test.patch # noop move
499 $ hg qpush --move test.patch # noop move
496 applying test.patch
500 applying test.patch
497 now at: test.patch
501 now at: test.patch
498 $ hg qseries -v
502 $ hg qseries -v
499 0 A test2.patch
503 0 A test2.patch
500 1 A test1b.patch
504 1 A test1b.patch
501 2 A test.patch
505 2 A test.patch
502 $ hg qpop -a
506 $ hg qpop -a
503 popping test.patch
507 popping test.patch
504 popping test1b.patch
508 popping test1b.patch
505 popping test2.patch
509 popping test2.patch
506 patch queue now empty
510 patch queue now empty
507
511
508 cleaning up
512 cleaning up
509
513
510 $ hg qselect --none
514 $ hg qselect --none
511 guards deactivated
515 guards deactivated
512 number of unguarded, unapplied patches has changed from 3 to 2
516 number of unguarded, unapplied patches has changed from 3 to 2
513 $ hg qguard --none test1b.patch
517 $ hg qguard --none test1b.patch
514 $ hg qguard --none test2.patch
518 $ hg qguard --none test2.patch
515 $ hg qpush --move test.patch
519 $ hg qpush --move test.patch
516 applying test.patch
520 applying test.patch
517 now at: test.patch
521 now at: test.patch
518 $ hg qpush --move test1b.patch
522 $ hg qpush --move test1b.patch
519 applying test1b.patch
523 applying test1b.patch
520 now at: test1b.patch
524 now at: test1b.patch
521 $ hg qpush --move bogus # nonexistent patch
525 $ hg qpush --move bogus # nonexistent patch
522 abort: patch bogus not in series
526 abort: patch bogus not in series
523 [255]
527 [255]
524 $ hg qpush --move # no patch
528 $ hg qpush --move # no patch
525 abort: please specify the patch to move
529 abort: please specify the patch to move
526 [255]
530 [255]
527 $ hg qpush --move test.patch # already applied
531 $ hg qpush --move test.patch # already applied
528 abort: cannot push to a previous patch: test.patch
532 abort: cannot push to a previous patch: test.patch
529 [255]
533 [255]
530 $ sed '2i\
534 $ sed '2i\
531 > # make qtip index different in series and fullseries
535 > # make qtip index different in series and fullseries
532 > ' `hg root`/.hg/patches/series > $TESTTMP/sedtmp
536 > ' `hg root`/.hg/patches/series > $TESTTMP/sedtmp
533 $ cp $TESTTMP/sedtmp `hg root`/.hg/patches/series
537 $ cp $TESTTMP/sedtmp `hg root`/.hg/patches/series
534 $ cat `hg root`/.hg/patches/series
538 $ cat `hg root`/.hg/patches/series
535 # comment
539 # comment
536 # make qtip index different in series and fullseries
540 # make qtip index different in series and fullseries
537
541
538 test.patch
542 test.patch
539 test1b.patch
543 test1b.patch
540 test2.patch
544 test2.patch
541 $ hg qpush --move test2.patch
545 $ hg qpush --move test2.patch
542 applying test2.patch
546 applying test2.patch
543 now at: test2.patch
547 now at: test2.patch
544
548
545
549
546 series after move
550 series after move
547
551
548 $ cat `hg root`/.hg/patches/series
552 $ cat `hg root`/.hg/patches/series
549 # comment
553 # comment
550 # make qtip index different in series and fullseries
554 # make qtip index different in series and fullseries
551
555
552 test.patch
556 test.patch
553 test1b.patch
557 test1b.patch
554 test2.patch
558 test2.patch
555
559
556
560
557 pop, qapplied, qunapplied
561 pop, qapplied, qunapplied
558
562
559 $ hg qseries -v
563 $ hg qseries -v
560 0 A test.patch
564 0 A test.patch
561 1 A test1b.patch
565 1 A test1b.patch
562 2 A test2.patch
566 2 A test2.patch
563
567
564 qapplied -1 test.patch
568 qapplied -1 test.patch
565
569
566 $ hg qapplied -1 test.patch
570 $ hg qapplied -1 test.patch
567 only one patch applied
571 only one patch applied
568 [1]
572 [1]
569
573
570 qapplied -1 test1b.patch
574 qapplied -1 test1b.patch
571
575
572 $ hg qapplied -1 test1b.patch
576 $ hg qapplied -1 test1b.patch
573 test.patch
577 test.patch
574
578
575 qapplied -1 test2.patch
579 qapplied -1 test2.patch
576
580
577 $ hg qapplied -1 test2.patch
581 $ hg qapplied -1 test2.patch
578 test1b.patch
582 test1b.patch
579
583
580 qapplied -1
584 qapplied -1
581
585
582 $ hg qapplied -1
586 $ hg qapplied -1
583 test1b.patch
587 test1b.patch
584
588
585 qapplied
589 qapplied
586
590
587 $ hg qapplied
591 $ hg qapplied
588 test.patch
592 test.patch
589 test1b.patch
593 test1b.patch
590 test2.patch
594 test2.patch
591
595
592 qapplied test1b.patch
596 qapplied test1b.patch
593
597
594 $ hg qapplied test1b.patch
598 $ hg qapplied test1b.patch
595 test.patch
599 test.patch
596 test1b.patch
600 test1b.patch
597
601
598 qunapplied -1
602 qunapplied -1
599
603
600 $ hg qunapplied -1
604 $ hg qunapplied -1
601 all patches applied
605 all patches applied
602 [1]
606 [1]
603
607
604 qunapplied
608 qunapplied
605
609
606 $ hg qunapplied
610 $ hg qunapplied
607
611
608 popping
612 popping
609
613
610 $ hg qpop
614 $ hg qpop
611 popping test2.patch
615 popping test2.patch
612 now at: test1b.patch
616 now at: test1b.patch
613
617
614 qunapplied -1
618 qunapplied -1
615
619
616 $ hg qunapplied -1
620 $ hg qunapplied -1
617 test2.patch
621 test2.patch
618
622
619 qunapplied
623 qunapplied
620
624
621 $ hg qunapplied
625 $ hg qunapplied
622 test2.patch
626 test2.patch
623
627
624 qunapplied test2.patch
628 qunapplied test2.patch
625
629
626 $ hg qunapplied test2.patch
630 $ hg qunapplied test2.patch
627
631
628 qunapplied -1 test2.patch
632 qunapplied -1 test2.patch
629
633
630 $ hg qunapplied -1 test2.patch
634 $ hg qunapplied -1 test2.patch
631 all patches applied
635 all patches applied
632 [1]
636 [1]
633
637
634 popping -a
638 popping -a
635
639
636 $ hg qpop -a
640 $ hg qpop -a
637 popping test1b.patch
641 popping test1b.patch
638 popping test.patch
642 popping test.patch
639 patch queue now empty
643 patch queue now empty
640
644
641 qapplied
645 qapplied
642
646
643 $ hg qapplied
647 $ hg qapplied
644
648
645 qapplied -1
649 qapplied -1
646
650
647 $ hg qapplied -1
651 $ hg qapplied -1
648 no patches applied
652 no patches applied
649 [1]
653 [1]
650 $ hg qpush
654 $ hg qpush
651 applying test.patch
655 applying test.patch
652 now at: test.patch
656 now at: test.patch
653
657
654
658
655 push should succeed
659 push should succeed
656
660
657 $ hg qpop -a
661 $ hg qpop -a
658 popping test.patch
662 popping test.patch
659 patch queue now empty
663 patch queue now empty
660 $ hg push ../../k
664 $ hg push ../../k
661 pushing to ../../k
665 pushing to ../../k
662 searching for changes
666 searching for changes
663 adding changesets
667 adding changesets
664 adding manifests
668 adding manifests
665 adding file changes
669 adding file changes
666 added 1 changesets with 1 changes to 1 files
670 added 1 changesets with 1 changes to 1 files
667
671
668
672
669 we want to start with some patches applied
673 we want to start with some patches applied
670
674
671 $ hg qpush -a
675 $ hg qpush -a
672 applying test.patch
676 applying test.patch
673 applying test1b.patch
677 applying test1b.patch
674 applying test2.patch
678 applying test2.patch
675 now at: test2.patch
679 now at: test2.patch
676
680
677 % pops all patches and succeeds
681 % pops all patches and succeeds
678
682
679 $ hg qpop -a
683 $ hg qpop -a
680 popping test2.patch
684 popping test2.patch
681 popping test1b.patch
685 popping test1b.patch
682 popping test.patch
686 popping test.patch
683 patch queue now empty
687 patch queue now empty
684
688
685 % does nothing and succeeds
689 % does nothing and succeeds
686
690
687 $ hg qpop -a
691 $ hg qpop -a
688 no patches applied
692 no patches applied
689
693
690 % fails - nothing else to pop
694 % fails - nothing else to pop
691
695
692 $ hg qpop
696 $ hg qpop
693 no patches applied
697 no patches applied
694 [1]
698 [1]
695
699
696 % pushes a patch and succeeds
700 % pushes a patch and succeeds
697
701
698 $ hg qpush
702 $ hg qpush
699 applying test.patch
703 applying test.patch
700 now at: test.patch
704 now at: test.patch
701
705
702 % pops a patch and succeeds
706 % pops a patch and succeeds
703
707
704 $ hg qpop
708 $ hg qpop
705 popping test.patch
709 popping test.patch
706 patch queue now empty
710 patch queue now empty
707
711
708 % pushes up to test1b.patch and succeeds
712 % pushes up to test1b.patch and succeeds
709
713
710 $ hg qpush test1b.patch
714 $ hg qpush test1b.patch
711 applying test.patch
715 applying test.patch
712 applying test1b.patch
716 applying test1b.patch
713 now at: test1b.patch
717 now at: test1b.patch
714
718
715 % does nothing and succeeds
719 % does nothing and succeeds
716
720
717 $ hg qpush test1b.patch
721 $ hg qpush test1b.patch
718 qpush: test1b.patch is already at the top
722 qpush: test1b.patch is already at the top
719
723
720 % does nothing and succeeds
724 % does nothing and succeeds
721
725
722 $ hg qpop test1b.patch
726 $ hg qpop test1b.patch
723 qpop: test1b.patch is already at the top
727 qpop: test1b.patch is already at the top
724
728
725 % fails - can't push to this patch
729 % fails - can't push to this patch
726
730
727 $ hg qpush test.patch
731 $ hg qpush test.patch
728 abort: cannot push to a previous patch: test.patch
732 abort: cannot push to a previous patch: test.patch
729 [255]
733 [255]
730
734
731 % fails - can't pop to this patch
735 % fails - can't pop to this patch
732
736
733 $ hg qpop test2.patch
737 $ hg qpop test2.patch
734 abort: patch test2.patch is not applied
738 abort: patch test2.patch is not applied
735 [255]
739 [255]
736
740
737 % pops up to test.patch and succeeds
741 % pops up to test.patch and succeeds
738
742
739 $ hg qpop test.patch
743 $ hg qpop test.patch
740 popping test1b.patch
744 popping test1b.patch
741 now at: test.patch
745 now at: test.patch
742
746
743 % pushes all patches and succeeds
747 % pushes all patches and succeeds
744
748
745 $ hg qpush -a
749 $ hg qpush -a
746 applying test1b.patch
750 applying test1b.patch
747 applying test2.patch
751 applying test2.patch
748 now at: test2.patch
752 now at: test2.patch
749
753
750 % does nothing and succeeds
754 % does nothing and succeeds
751
755
752 $ hg qpush -a
756 $ hg qpush -a
753 all patches are currently applied
757 all patches are currently applied
754
758
755 % fails - nothing else to push
759 % fails - nothing else to push
756
760
757 $ hg qpush
761 $ hg qpush
758 patch series already fully applied
762 patch series already fully applied
759 [1]
763 [1]
760
764
761 % does nothing and succeeds
765 % does nothing and succeeds
762
766
763 $ hg qpush test2.patch
767 $ hg qpush test2.patch
764 qpush: test2.patch is already at the top
768 qpush: test2.patch is already at the top
765
769
766 strip
770 strip
767
771
768 $ cd ../../b
772 $ cd ../../b
769 $ echo x>x
773 $ echo x>x
770 $ hg ci -Ama
774 $ hg ci -Ama
771 adding x
775 adding x
772 $ hg strip tip
776 $ hg strip tip
773 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
777 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
774 saved backup bundle to $TESTTMP/b/.hg/strip-backup/*-backup.hg (glob)
778 saved backup bundle to $TESTTMP/b/.hg/strip-backup/*-backup.hg (glob)
775 $ hg unbundle .hg/strip-backup/*
779 $ hg unbundle .hg/strip-backup/*
776 adding changesets
780 adding changesets
777 adding manifests
781 adding manifests
778 adding file changes
782 adding file changes
779 added 1 changesets with 1 changes to 1 files
783 added 1 changesets with 1 changes to 1 files
780 (run 'hg update' to get a working copy)
784 (run 'hg update' to get a working copy)
781
785
782
786
783 strip with local changes, should complain
787 strip with local changes, should complain
784
788
785 $ hg up
789 $ hg up
786 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
790 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
787 $ echo y>y
791 $ echo y>y
788 $ hg add y
792 $ hg add y
789 $ hg strip tip
793 $ hg strip tip
790 abort: local changes found
794 abort: local changes found
791 [255]
795 [255]
792
796
793 --force strip with local changes
797 --force strip with local changes
794
798
795 $ hg strip -f tip
799 $ hg strip -f tip
796 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
800 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
797 saved backup bundle to $TESTTMP/b/.hg/strip-backup/*-backup.hg (glob)
801 saved backup bundle to $TESTTMP/b/.hg/strip-backup/*-backup.hg (glob)
798 $ cd ..
802 $ cd ..
799
803
800
804
801 cd b; hg qrefresh
805 cd b; hg qrefresh
802
806
803 $ hg init refresh
807 $ hg init refresh
804 $ cd refresh
808 $ cd refresh
805 $ echo a > a
809 $ echo a > a
806 $ hg ci -Ama
810 $ hg ci -Ama
807 adding a
811 adding a
808 $ hg qnew -mfoo foo
812 $ hg qnew -mfoo foo
809 $ echo a >> a
813 $ echo a >> a
810 $ hg qrefresh
814 $ hg qrefresh
811 $ mkdir b
815 $ mkdir b
812 $ cd b
816 $ cd b
813 $ echo f > f
817 $ echo f > f
814 $ hg add f
818 $ hg add f
815 $ hg qrefresh
819 $ hg qrefresh
816 $ cat ../.hg/patches/foo
820 $ cat ../.hg/patches/foo
817 foo
821 foo
818
822
819 diff -r cb9a9f314b8b a
823 diff -r cb9a9f314b8b a
820 --- a/a\t(?P<date>.*) (re)
824 --- a/a\t(?P<date>.*) (re)
821 \+\+\+ b/a\t(?P<date>.*) (re)
825 \+\+\+ b/a\t(?P<date>.*) (re)
822 @@ -1,1 +1,2 @@
826 @@ -1,1 +1,2 @@
823 a
827 a
824 +a
828 +a
825 diff -r cb9a9f314b8b b/f
829 diff -r cb9a9f314b8b b/f
826 --- /dev/null\t(?P<date>.*) (re)
830 --- /dev/null\t(?P<date>.*) (re)
827 \+\+\+ b/b/f\t(?P<date>.*) (re)
831 \+\+\+ b/b/f\t(?P<date>.*) (re)
828 @@ -0,0 +1,1 @@
832 @@ -0,0 +1,1 @@
829 +f
833 +f
830
834
831 hg qrefresh .
835 hg qrefresh .
832
836
833 $ hg qrefresh .
837 $ hg qrefresh .
834 $ cat ../.hg/patches/foo
838 $ cat ../.hg/patches/foo
835 foo
839 foo
836
840
837 diff -r cb9a9f314b8b b/f
841 diff -r cb9a9f314b8b b/f
838 --- /dev/null\t(?P<date>.*) (re)
842 --- /dev/null\t(?P<date>.*) (re)
839 \+\+\+ b/b/f\t(?P<date>.*) (re)
843 \+\+\+ b/b/f\t(?P<date>.*) (re)
840 @@ -0,0 +1,1 @@
844 @@ -0,0 +1,1 @@
841 +f
845 +f
842 $ hg status
846 $ hg status
843 M a
847 M a
844
848
845
849
846 qpush failure
850 qpush failure
847
851
848 $ cd ..
852 $ cd ..
849 $ hg qrefresh
853 $ hg qrefresh
850 $ hg qnew -mbar bar
854 $ hg qnew -mbar bar
851 $ echo foo > foo
855 $ echo foo > foo
852 $ echo bar > bar
856 $ echo bar > bar
853 $ hg add foo bar
857 $ hg add foo bar
854 $ hg qrefresh
858 $ hg qrefresh
855 $ hg qpop -a
859 $ hg qpop -a
856 popping bar
860 popping bar
857 popping foo
861 popping foo
858 patch queue now empty
862 patch queue now empty
859 $ echo bar > foo
863 $ echo bar > foo
860 $ hg qpush -a
864 $ hg qpush -a
861 applying foo
865 applying foo
862 applying bar
866 applying bar
863 file foo already exists
867 file foo already exists
864 1 out of 1 hunks FAILED -- saving rejects to file foo.rej
868 1 out of 1 hunks FAILED -- saving rejects to file foo.rej
865 patch failed, unable to continue (try -v)
869 patch failed, unable to continue (try -v)
866 patch failed, rejects left in working dir
870 patch failed, rejects left in working dir
867 errors during apply, please fix and refresh bar
871 errors during apply, please fix and refresh bar
868 [2]
872 [2]
869 $ hg st
873 $ hg st
870 ? foo
874 ? foo
871 ? foo.rej
875 ? foo.rej
872
876
873
877
874 mq tags
878 mq tags
875
879
876 $ hg log --template '{rev} {tags}\n' -r qparent:qtip
880 $ hg log --template '{rev} {tags}\n' -r qparent:qtip
877 0 qparent
881 0 qparent
878 1 foo qbase
882 1 foo qbase
879 2 bar qtip tip
883 2 bar qtip tip
880
884
881 mq revset
885 mq revset
882
886
883 $ hg log -r 'mq()' --template '{rev}\n'
887 $ hg log -r 'mq()' --template '{rev}\n'
884 1
888 1
885 2
889 2
886 $ hg help revsets | grep -i mq
890 $ hg help revsets | grep -i mq
887 "mq()"
891 "mq()"
888 Changesets managed by MQ.
892 Changesets managed by MQ.
889
893
890 bad node in status
894 bad node in status
891
895
892 $ hg qpop
896 $ hg qpop
893 popping bar
897 popping bar
894 now at: foo
898 now at: foo
895 $ hg strip -qn tip
899 $ hg strip -qn tip
896 $ hg tip
900 $ hg tip
897 changeset: 0:cb9a9f314b8b
901 changeset: 0:cb9a9f314b8b
898 tag: tip
902 tag: tip
899 user: test
903 user: test
900 date: Thu Jan 01 00:00:00 1970 +0000
904 date: Thu Jan 01 00:00:00 1970 +0000
901 summary: a
905 summary: a
902
906
903 $ hg branches
907 $ hg branches
904 default 0:cb9a9f314b8b
908 default 0:cb9a9f314b8b
905 $ hg qpop
909 $ hg qpop
906 no patches applied
910 no patches applied
907 [1]
911 [1]
908
912
909 $ cd ..
913 $ cd ..
910
914
911
915
912 git patches
916 git patches
913
917
914 $ cat >>$HGRCPATH <<EOF
918 $ cat >>$HGRCPATH <<EOF
915 > [diff]
919 > [diff]
916 > git = True
920 > git = True
917 > EOF
921 > EOF
918 $ hg init git
922 $ hg init git
919 $ cd git
923 $ cd git
920 $ hg qinit
924 $ hg qinit
921
925
922 $ hg qnew -m'new file' new
926 $ hg qnew -m'new file' new
923 $ echo foo > new
927 $ echo foo > new
924 #if execbit
928 #if execbit
925 $ chmod +x new
929 $ chmod +x new
926 #endif
930 #endif
927 $ hg add new
931 $ hg add new
928 $ hg qrefresh
932 $ hg qrefresh
929 #if execbit
933 #if execbit
930 $ cat .hg/patches/new
934 $ cat .hg/patches/new
931 new file
935 new file
932
936
933 diff --git a/new b/new
937 diff --git a/new b/new
934 new file mode 100755
938 new file mode 100755
935 --- /dev/null
939 --- /dev/null
936 +++ b/new
940 +++ b/new
937 @@ -0,0 +1,1 @@
941 @@ -0,0 +1,1 @@
938 +foo
942 +foo
939 #else
943 #else
940 $ cat .hg/patches/new
944 $ cat .hg/patches/new
941 new file
945 new file
942
946
943 diff --git a/new b/new
947 diff --git a/new b/new
944 new file mode 100644
948 new file mode 100644
945 --- /dev/null
949 --- /dev/null
946 +++ b/new
950 +++ b/new
947 @@ -0,0 +1,1 @@
951 @@ -0,0 +1,1 @@
948 +foo
952 +foo
949 #endif
953 #endif
950
954
951 $ hg qnew -m'copy file' copy
955 $ hg qnew -m'copy file' copy
952 $ hg cp new copy
956 $ hg cp new copy
953 $ hg qrefresh
957 $ hg qrefresh
954 $ cat .hg/patches/copy
958 $ cat .hg/patches/copy
955 copy file
959 copy file
956
960
957 diff --git a/new b/copy
961 diff --git a/new b/copy
958 copy from new
962 copy from new
959 copy to copy
963 copy to copy
960
964
961 $ hg qpop
965 $ hg qpop
962 popping copy
966 popping copy
963 now at: new
967 now at: new
964 $ hg qpush
968 $ hg qpush
965 applying copy
969 applying copy
966 now at: copy
970 now at: copy
967 $ hg qdiff
971 $ hg qdiff
968 diff --git a/new b/copy
972 diff --git a/new b/copy
969 copy from new
973 copy from new
970 copy to copy
974 copy to copy
971 $ cat >>$HGRCPATH <<EOF
975 $ cat >>$HGRCPATH <<EOF
972 > [diff]
976 > [diff]
973 > git = False
977 > git = False
974 > EOF
978 > EOF
975 $ hg qdiff --git
979 $ hg qdiff --git
976 diff --git a/new b/copy
980 diff --git a/new b/copy
977 copy from new
981 copy from new
978 copy to copy
982 copy to copy
979 $ cd ..
983 $ cd ..
980
984
981 empty lines in status
985 empty lines in status
982
986
983 $ hg init emptystatus
987 $ hg init emptystatus
984 $ cd emptystatus
988 $ cd emptystatus
985 $ hg qinit
989 $ hg qinit
986 $ printf '\n\n' > .hg/patches/status
990 $ printf '\n\n' > .hg/patches/status
987 $ hg qser
991 $ hg qser
988 $ cd ..
992 $ cd ..
989
993
990 bad line in status (without ":")
994 bad line in status (without ":")
991
995
992 $ hg init badstatus
996 $ hg init badstatus
993 $ cd badstatus
997 $ cd badstatus
994 $ hg qinit
998 $ hg qinit
995 $ printf 'babar has no colon in this line\n' > .hg/patches/status
999 $ printf 'babar has no colon in this line\n' > .hg/patches/status
996 $ hg qser
1000 $ hg qser
997 malformated mq status line: ['babar has no colon in this line']
1001 malformated mq status line: ['babar has no colon in this line']
998 $ cd ..
1002 $ cd ..
999
1003
1000
1004
1001 test file addition in slow path
1005 test file addition in slow path
1002
1006
1003 $ hg init slow
1007 $ hg init slow
1004 $ cd slow
1008 $ cd slow
1005 $ hg qinit
1009 $ hg qinit
1006 $ echo foo > foo
1010 $ echo foo > foo
1007 $ hg add foo
1011 $ hg add foo
1008 $ hg ci -m 'add foo'
1012 $ hg ci -m 'add foo'
1009 $ hg qnew bar
1013 $ hg qnew bar
1010 $ echo bar > bar
1014 $ echo bar > bar
1011 $ hg add bar
1015 $ hg add bar
1012 $ hg mv foo baz
1016 $ hg mv foo baz
1013 $ hg qrefresh --git
1017 $ hg qrefresh --git
1014 $ hg up -C 0
1018 $ hg up -C 0
1015 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
1019 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
1016 $ echo >> foo
1020 $ echo >> foo
1017 $ hg ci -m 'change foo'
1021 $ hg ci -m 'change foo'
1018 created new head
1022 created new head
1019 $ hg up -C 1
1023 $ hg up -C 1
1020 2 files updated, 0 files merged, 1 files removed, 0 files unresolved
1024 2 files updated, 0 files merged, 1 files removed, 0 files unresolved
1021 $ hg qrefresh --git
1025 $ hg qrefresh --git
1022 $ cat .hg/patches/bar
1026 $ cat .hg/patches/bar
1023 diff --git a/bar b/bar
1027 diff --git a/bar b/bar
1024 new file mode 100644
1028 new file mode 100644
1025 --- /dev/null
1029 --- /dev/null
1026 +++ b/bar
1030 +++ b/bar
1027 @@ -0,0 +1,1 @@
1031 @@ -0,0 +1,1 @@
1028 +bar
1032 +bar
1029 diff --git a/foo b/baz
1033 diff --git a/foo b/baz
1030 rename from foo
1034 rename from foo
1031 rename to baz
1035 rename to baz
1032 $ hg log -v --template '{rev} {file_copies}\n' -r .
1036 $ hg log -v --template '{rev} {file_copies}\n' -r .
1033 2 baz (foo)
1037 2 baz (foo)
1034 $ hg qrefresh --git
1038 $ hg qrefresh --git
1035 $ cat .hg/patches/bar
1039 $ cat .hg/patches/bar
1036 diff --git a/bar b/bar
1040 diff --git a/bar b/bar
1037 new file mode 100644
1041 new file mode 100644
1038 --- /dev/null
1042 --- /dev/null
1039 +++ b/bar
1043 +++ b/bar
1040 @@ -0,0 +1,1 @@
1044 @@ -0,0 +1,1 @@
1041 +bar
1045 +bar
1042 diff --git a/foo b/baz
1046 diff --git a/foo b/baz
1043 rename from foo
1047 rename from foo
1044 rename to baz
1048 rename to baz
1045 $ hg log -v --template '{rev} {file_copies}\n' -r .
1049 $ hg log -v --template '{rev} {file_copies}\n' -r .
1046 2 baz (foo)
1050 2 baz (foo)
1047 $ hg qrefresh
1051 $ hg qrefresh
1048 $ grep 'diff --git' .hg/patches/bar
1052 $ grep 'diff --git' .hg/patches/bar
1049 diff --git a/bar b/bar
1053 diff --git a/bar b/bar
1050 diff --git a/foo b/baz
1054 diff --git a/foo b/baz
1051
1055
1052
1056
1053 test file move chains in the slow path
1057 test file move chains in the slow path
1054
1058
1055 $ hg up -C 1
1059 $ hg up -C 1
1056 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
1060 1 files updated, 0 files merged, 2 files removed, 0 files unresolved
1057 $ echo >> foo
1061 $ echo >> foo
1058 $ hg ci -m 'change foo again'
1062 $ hg ci -m 'change foo again'
1059 $ hg up -C 2
1063 $ hg up -C 2
1060 2 files updated, 0 files merged, 1 files removed, 0 files unresolved
1064 2 files updated, 0 files merged, 1 files removed, 0 files unresolved
1061 $ hg mv bar quux
1065 $ hg mv bar quux
1062 $ hg mv baz bleh
1066 $ hg mv baz bleh
1063 $ hg qrefresh --git
1067 $ hg qrefresh --git
1064 $ cat .hg/patches/bar
1068 $ cat .hg/patches/bar
1065 diff --git a/foo b/bleh
1069 diff --git a/foo b/bleh
1066 rename from foo
1070 rename from foo
1067 rename to bleh
1071 rename to bleh
1068 diff --git a/quux b/quux
1072 diff --git a/quux b/quux
1069 new file mode 100644
1073 new file mode 100644
1070 --- /dev/null
1074 --- /dev/null
1071 +++ b/quux
1075 +++ b/quux
1072 @@ -0,0 +1,1 @@
1076 @@ -0,0 +1,1 @@
1073 +bar
1077 +bar
1074 $ hg log -v --template '{rev} {file_copies}\n' -r .
1078 $ hg log -v --template '{rev} {file_copies}\n' -r .
1075 3 bleh (foo)
1079 3 bleh (foo)
1076 $ hg mv quux fred
1080 $ hg mv quux fred
1077 $ hg mv bleh barney
1081 $ hg mv bleh barney
1078 $ hg qrefresh --git
1082 $ hg qrefresh --git
1079 $ cat .hg/patches/bar
1083 $ cat .hg/patches/bar
1080 diff --git a/foo b/barney
1084 diff --git a/foo b/barney
1081 rename from foo
1085 rename from foo
1082 rename to barney
1086 rename to barney
1083 diff --git a/fred b/fred
1087 diff --git a/fred b/fred
1084 new file mode 100644
1088 new file mode 100644
1085 --- /dev/null
1089 --- /dev/null
1086 +++ b/fred
1090 +++ b/fred
1087 @@ -0,0 +1,1 @@
1091 @@ -0,0 +1,1 @@
1088 +bar
1092 +bar
1089 $ hg log -v --template '{rev} {file_copies}\n' -r .
1093 $ hg log -v --template '{rev} {file_copies}\n' -r .
1090 3 barney (foo)
1094 3 barney (foo)
1091
1095
1092
1096
1093 refresh omitting an added file
1097 refresh omitting an added file
1094
1098
1095 $ hg qnew baz
1099 $ hg qnew baz
1096 $ echo newfile > newfile
1100 $ echo newfile > newfile
1097 $ hg add newfile
1101 $ hg add newfile
1098 $ hg qrefresh
1102 $ hg qrefresh
1099 $ hg st -A newfile
1103 $ hg st -A newfile
1100 C newfile
1104 C newfile
1101 $ hg qrefresh -X newfile
1105 $ hg qrefresh -X newfile
1102 $ hg st -A newfile
1106 $ hg st -A newfile
1103 A newfile
1107 A newfile
1104 $ hg revert newfile
1108 $ hg revert newfile
1105 $ rm newfile
1109 $ rm newfile
1106 $ hg qpop
1110 $ hg qpop
1107 popping baz
1111 popping baz
1108 now at: bar
1112 now at: bar
1109 $ hg qdel baz
1113 $ hg qdel baz
1110
1114
1111
1115
1112 create a git patch
1116 create a git patch
1113
1117
1114 $ echo a > alexander
1118 $ echo a > alexander
1115 $ hg add alexander
1119 $ hg add alexander
1116 $ hg qnew -f --git addalexander
1120 $ hg qnew -f --git addalexander
1117 $ grep diff .hg/patches/addalexander
1121 $ grep diff .hg/patches/addalexander
1118 diff --git a/alexander b/alexander
1122 diff --git a/alexander b/alexander
1119
1123
1120
1124
1121 create a git binary patch
1125 create a git binary patch
1122
1126
1123 $ cat > writebin.py <<EOF
1127 $ cat > writebin.py <<EOF
1124 > import sys
1128 > import sys
1125 > path = sys.argv[1]
1129 > path = sys.argv[1]
1126 > open(path, 'wb').write('BIN\x00ARY')
1130 > open(path, 'wb').write('BIN\x00ARY')
1127 > EOF
1131 > EOF
1128 $ python writebin.py bucephalus
1132 $ python writebin.py bucephalus
1129
1133
1130 $ python "$TESTDIR/md5sum.py" bucephalus
1134 $ python "$TESTDIR/md5sum.py" bucephalus
1131 8ba2a2f3e77b55d03051ff9c24ad65e7 bucephalus
1135 8ba2a2f3e77b55d03051ff9c24ad65e7 bucephalus
1132 $ hg add bucephalus
1136 $ hg add bucephalus
1133 $ hg qnew -f --git addbucephalus
1137 $ hg qnew -f --git addbucephalus
1134 $ grep diff .hg/patches/addbucephalus
1138 $ grep diff .hg/patches/addbucephalus
1135 diff --git a/bucephalus b/bucephalus
1139 diff --git a/bucephalus b/bucephalus
1136
1140
1137
1141
1138 check binary patches can be popped and pushed
1142 check binary patches can be popped and pushed
1139
1143
1140 $ hg qpop
1144 $ hg qpop
1141 popping addbucephalus
1145 popping addbucephalus
1142 now at: addalexander
1146 now at: addalexander
1143 $ test -f bucephalus && echo % bucephalus should not be there
1147 $ test -f bucephalus && echo % bucephalus should not be there
1144 [1]
1148 [1]
1145 $ hg qpush
1149 $ hg qpush
1146 applying addbucephalus
1150 applying addbucephalus
1147 now at: addbucephalus
1151 now at: addbucephalus
1148 $ test -f bucephalus
1152 $ test -f bucephalus
1149 $ python "$TESTDIR/md5sum.py" bucephalus
1153 $ python "$TESTDIR/md5sum.py" bucephalus
1150 8ba2a2f3e77b55d03051ff9c24ad65e7 bucephalus
1154 8ba2a2f3e77b55d03051ff9c24ad65e7 bucephalus
1151
1155
1152
1156
1153
1157
1154 strip again
1158 strip again
1155
1159
1156 $ cd ..
1160 $ cd ..
1157 $ hg init strip
1161 $ hg init strip
1158 $ cd strip
1162 $ cd strip
1159 $ touch foo
1163 $ touch foo
1160 $ hg add foo
1164 $ hg add foo
1161 $ hg ci -m 'add foo'
1165 $ hg ci -m 'add foo'
1162 $ echo >> foo
1166 $ echo >> foo
1163 $ hg ci -m 'change foo 1'
1167 $ hg ci -m 'change foo 1'
1164 $ hg up -C 0
1168 $ hg up -C 0
1165 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1169 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1166 $ echo 1 >> foo
1170 $ echo 1 >> foo
1167 $ hg ci -m 'change foo 2'
1171 $ hg ci -m 'change foo 2'
1168 created new head
1172 created new head
1169 $ HGMERGE=true hg merge
1173 $ HGMERGE=true hg merge
1170 merging foo
1174 merging foo
1171 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
1175 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
1172 (branch merge, don't forget to commit)
1176 (branch merge, don't forget to commit)
1173 $ hg ci -m merge
1177 $ hg ci -m merge
1174 $ hg log
1178 $ hg log
1175 changeset: 3:99615015637b
1179 changeset: 3:99615015637b
1176 tag: tip
1180 tag: tip
1177 parent: 2:20cbbe65cff7
1181 parent: 2:20cbbe65cff7
1178 parent: 1:d2871fc282d4
1182 parent: 1:d2871fc282d4
1179 user: test
1183 user: test
1180 date: Thu Jan 01 00:00:00 1970 +0000
1184 date: Thu Jan 01 00:00:00 1970 +0000
1181 summary: merge
1185 summary: merge
1182
1186
1183 changeset: 2:20cbbe65cff7
1187 changeset: 2:20cbbe65cff7
1184 parent: 0:53245c60e682
1188 parent: 0:53245c60e682
1185 user: test
1189 user: test
1186 date: Thu Jan 01 00:00:00 1970 +0000
1190 date: Thu Jan 01 00:00:00 1970 +0000
1187 summary: change foo 2
1191 summary: change foo 2
1188
1192
1189 changeset: 1:d2871fc282d4
1193 changeset: 1:d2871fc282d4
1190 user: test
1194 user: test
1191 date: Thu Jan 01 00:00:00 1970 +0000
1195 date: Thu Jan 01 00:00:00 1970 +0000
1192 summary: change foo 1
1196 summary: change foo 1
1193
1197
1194 changeset: 0:53245c60e682
1198 changeset: 0:53245c60e682
1195 user: test
1199 user: test
1196 date: Thu Jan 01 00:00:00 1970 +0000
1200 date: Thu Jan 01 00:00:00 1970 +0000
1197 summary: add foo
1201 summary: add foo
1198
1202
1199 $ hg strip 1
1203 $ hg strip 1
1200 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1204 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1201 saved backup bundle to $TESTTMP/strip/.hg/strip-backup/*-backup.hg (glob)
1205 saved backup bundle to $TESTTMP/strip/.hg/strip-backup/*-backup.hg (glob)
1202 $ checkundo strip
1206 $ checkundo strip
1203 $ hg log
1207 $ hg log
1204 changeset: 1:20cbbe65cff7
1208 changeset: 1:20cbbe65cff7
1205 tag: tip
1209 tag: tip
1206 user: test
1210 user: test
1207 date: Thu Jan 01 00:00:00 1970 +0000
1211 date: Thu Jan 01 00:00:00 1970 +0000
1208 summary: change foo 2
1212 summary: change foo 2
1209
1213
1210 changeset: 0:53245c60e682
1214 changeset: 0:53245c60e682
1211 user: test
1215 user: test
1212 date: Thu Jan 01 00:00:00 1970 +0000
1216 date: Thu Jan 01 00:00:00 1970 +0000
1213 summary: add foo
1217 summary: add foo
1214
1218
1215 $ cd ..
1219 $ cd ..
1216
1220
1217
1221
1218 qclone
1222 qclone
1219
1223
1220 $ qlog()
1224 $ qlog()
1221 > {
1225 > {
1222 > echo 'main repo:'
1226 > echo 'main repo:'
1223 > hg log --template ' rev {rev}: {desc}\n'
1227 > hg log --template ' rev {rev}: {desc}\n'
1224 > echo 'patch repo:'
1228 > echo 'patch repo:'
1225 > hg -R .hg/patches log --template ' rev {rev}: {desc}\n'
1229 > hg -R .hg/patches log --template ' rev {rev}: {desc}\n'
1226 > }
1230 > }
1227 $ hg init qclonesource
1231 $ hg init qclonesource
1228 $ cd qclonesource
1232 $ cd qclonesource
1229 $ echo foo > foo
1233 $ echo foo > foo
1230 $ hg add foo
1234 $ hg add foo
1231 $ hg ci -m 'add foo'
1235 $ hg ci -m 'add foo'
1232 $ hg qinit
1236 $ hg qinit
1233 $ hg qnew patch1
1237 $ hg qnew patch1
1234 $ echo bar >> foo
1238 $ echo bar >> foo
1235 $ hg qrefresh -m 'change foo'
1239 $ hg qrefresh -m 'change foo'
1236 $ cd ..
1240 $ cd ..
1237
1241
1238
1242
1239 repo with unversioned patch dir
1243 repo with unversioned patch dir
1240
1244
1241 $ hg qclone qclonesource failure
1245 $ hg qclone qclonesource failure
1242 abort: versioned patch repository not found (see init --mq)
1246 abort: versioned patch repository not found (see init --mq)
1243 [255]
1247 [255]
1244
1248
1245 $ cd qclonesource
1249 $ cd qclonesource
1246 $ hg qinit -c
1250 $ hg qinit -c
1247 adding .hg/patches/patch1 (glob)
1251 adding .hg/patches/patch1 (glob)
1248 $ hg qci -m checkpoint
1252 $ hg qci -m checkpoint
1249 $ qlog
1253 $ qlog
1250 main repo:
1254 main repo:
1251 rev 1: change foo
1255 rev 1: change foo
1252 rev 0: add foo
1256 rev 0: add foo
1253 patch repo:
1257 patch repo:
1254 rev 0: checkpoint
1258 rev 0: checkpoint
1255 $ cd ..
1259 $ cd ..
1256
1260
1257
1261
1258 repo with patches applied
1262 repo with patches applied
1259
1263
1260 $ hg qclone qclonesource qclonedest
1264 $ hg qclone qclonesource qclonedest
1261 updating to branch default
1265 updating to branch default
1262 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
1266 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
1263 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1267 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1264 $ cd qclonedest
1268 $ cd qclonedest
1265 $ qlog
1269 $ qlog
1266 main repo:
1270 main repo:
1267 rev 0: add foo
1271 rev 0: add foo
1268 patch repo:
1272 patch repo:
1269 rev 0: checkpoint
1273 rev 0: checkpoint
1270 $ cd ..
1274 $ cd ..
1271
1275
1272
1276
1273 repo with patches unapplied
1277 repo with patches unapplied
1274
1278
1275 $ cd qclonesource
1279 $ cd qclonesource
1276 $ hg qpop -a
1280 $ hg qpop -a
1277 popping patch1
1281 popping patch1
1278 patch queue now empty
1282 patch queue now empty
1279 $ qlog
1283 $ qlog
1280 main repo:
1284 main repo:
1281 rev 0: add foo
1285 rev 0: add foo
1282 patch repo:
1286 patch repo:
1283 rev 0: checkpoint
1287 rev 0: checkpoint
1284 $ cd ..
1288 $ cd ..
1285 $ hg qclone qclonesource qclonedest2
1289 $ hg qclone qclonesource qclonedest2
1286 updating to branch default
1290 updating to branch default
1287 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
1291 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
1288 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1292 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1289 $ cd qclonedest2
1293 $ cd qclonedest2
1290 $ qlog
1294 $ qlog
1291 main repo:
1295 main repo:
1292 rev 0: add foo
1296 rev 0: add foo
1293 patch repo:
1297 patch repo:
1294 rev 0: checkpoint
1298 rev 0: checkpoint
1295 $ cd ..
1299 $ cd ..
1296
1300
1297
1301
1298 Issue1033: test applying on an empty file
1302 Issue1033: test applying on an empty file
1299
1303
1300 $ hg init empty
1304 $ hg init empty
1301 $ cd empty
1305 $ cd empty
1302 $ touch a
1306 $ touch a
1303 $ hg ci -Am addempty
1307 $ hg ci -Am addempty
1304 adding a
1308 adding a
1305 $ echo a > a
1309 $ echo a > a
1306 $ hg qnew -f -e changea
1310 $ hg qnew -f -e changea
1307 $ hg qpop
1311 $ hg qpop
1308 popping changea
1312 popping changea
1309 patch queue now empty
1313 patch queue now empty
1310 $ hg qpush
1314 $ hg qpush
1311 applying changea
1315 applying changea
1312 now at: changea
1316 now at: changea
1313 $ cd ..
1317 $ cd ..
1314
1318
1315 test qpush with --force, issue1087
1319 test qpush with --force, issue1087
1316
1320
1317 $ hg init forcepush
1321 $ hg init forcepush
1318 $ cd forcepush
1322 $ cd forcepush
1319 $ echo hello > hello.txt
1323 $ echo hello > hello.txt
1320 $ echo bye > bye.txt
1324 $ echo bye > bye.txt
1321 $ hg ci -Ama
1325 $ hg ci -Ama
1322 adding bye.txt
1326 adding bye.txt
1323 adding hello.txt
1327 adding hello.txt
1324 $ hg qnew -d '0 0' empty
1328 $ hg qnew -d '0 0' empty
1325 $ hg qpop
1329 $ hg qpop
1326 popping empty
1330 popping empty
1327 patch queue now empty
1331 patch queue now empty
1328 $ echo world >> hello.txt
1332 $ echo world >> hello.txt
1329
1333
1330
1334
1331 qpush should fail, local changes
1335 qpush should fail, local changes
1332
1336
1333 $ hg qpush
1337 $ hg qpush
1334 abort: local changes found
1338 abort: local changes found
1335 [255]
1339 [255]
1336
1340
1337
1341
1338 apply force, should not discard changes with empty patch
1342 apply force, should not discard changes with empty patch
1339
1343
1340 $ hg qpush -f
1344 $ hg qpush -f
1341 applying empty
1345 applying empty
1342 patch empty is empty
1346 patch empty is empty
1343 now at: empty
1347 now at: empty
1344 $ hg diff --config diff.nodates=True
1348 $ hg diff --config diff.nodates=True
1345 diff -r d58265112590 hello.txt
1349 diff -r d58265112590 hello.txt
1346 --- a/hello.txt
1350 --- a/hello.txt
1347 +++ b/hello.txt
1351 +++ b/hello.txt
1348 @@ -1,1 +1,2 @@
1352 @@ -1,1 +1,2 @@
1349 hello
1353 hello
1350 +world
1354 +world
1351 $ hg qdiff --config diff.nodates=True
1355 $ hg qdiff --config diff.nodates=True
1352 diff -r 9ecee4f634e3 hello.txt
1356 diff -r 9ecee4f634e3 hello.txt
1353 --- a/hello.txt
1357 --- a/hello.txt
1354 +++ b/hello.txt
1358 +++ b/hello.txt
1355 @@ -1,1 +1,2 @@
1359 @@ -1,1 +1,2 @@
1356 hello
1360 hello
1357 +world
1361 +world
1358 $ hg log -l1 -p
1362 $ hg log -l1 -p
1359 changeset: 1:d58265112590
1363 changeset: 1:d58265112590
1360 tag: empty
1364 tag: empty
1361 tag: qbase
1365 tag: qbase
1362 tag: qtip
1366 tag: qtip
1363 tag: tip
1367 tag: tip
1364 user: test
1368 user: test
1365 date: Thu Jan 01 00:00:00 1970 +0000
1369 date: Thu Jan 01 00:00:00 1970 +0000
1366 summary: imported patch empty
1370 summary: imported patch empty
1367
1371
1368
1372
1369 $ hg qref -d '0 0'
1373 $ hg qref -d '0 0'
1370 $ hg qpop
1374 $ hg qpop
1371 popping empty
1375 popping empty
1372 patch queue now empty
1376 patch queue now empty
1373 $ echo universe >> hello.txt
1377 $ echo universe >> hello.txt
1374 $ echo universe >> bye.txt
1378 $ echo universe >> bye.txt
1375
1379
1376
1380
1377 qpush should fail, local changes
1381 qpush should fail, local changes
1378
1382
1379 $ hg qpush
1383 $ hg qpush
1380 abort: local changes found
1384 abort: local changes found
1381 [255]
1385 [255]
1382
1386
1383
1387
1384 apply force, should discard changes in hello, but not bye
1388 apply force, should discard changes in hello, but not bye
1385
1389
1386 $ hg qpush -f --verbose
1390 $ hg qpush -f --verbose
1387 applying empty
1391 applying empty
1388 saving current version of hello.txt as hello.txt.orig
1392 saving current version of hello.txt as hello.txt.orig
1389 patching file hello.txt
1393 patching file hello.txt
1390 hello.txt
1394 hello.txt
1391 now at: empty
1395 now at: empty
1392 $ hg st
1396 $ hg st
1393 M bye.txt
1397 M bye.txt
1394 ? hello.txt.orig
1398 ? hello.txt.orig
1395 $ hg diff --config diff.nodates=True
1399 $ hg diff --config diff.nodates=True
1396 diff -r ba252371dbc1 bye.txt
1400 diff -r ba252371dbc1 bye.txt
1397 --- a/bye.txt
1401 --- a/bye.txt
1398 +++ b/bye.txt
1402 +++ b/bye.txt
1399 @@ -1,1 +1,2 @@
1403 @@ -1,1 +1,2 @@
1400 bye
1404 bye
1401 +universe
1405 +universe
1402 $ hg qdiff --config diff.nodates=True
1406 $ hg qdiff --config diff.nodates=True
1403 diff -r 9ecee4f634e3 bye.txt
1407 diff -r 9ecee4f634e3 bye.txt
1404 --- a/bye.txt
1408 --- a/bye.txt
1405 +++ b/bye.txt
1409 +++ b/bye.txt
1406 @@ -1,1 +1,2 @@
1410 @@ -1,1 +1,2 @@
1407 bye
1411 bye
1408 +universe
1412 +universe
1409 diff -r 9ecee4f634e3 hello.txt
1413 diff -r 9ecee4f634e3 hello.txt
1410 --- a/hello.txt
1414 --- a/hello.txt
1411 +++ b/hello.txt
1415 +++ b/hello.txt
1412 @@ -1,1 +1,3 @@
1416 @@ -1,1 +1,3 @@
1413 hello
1417 hello
1414 +world
1418 +world
1415 +universe
1419 +universe
1416
1420
1417
1421
1418 test popping revisions not in working dir ancestry
1422 test popping revisions not in working dir ancestry
1419
1423
1420 $ hg qseries -v
1424 $ hg qseries -v
1421 0 A empty
1425 0 A empty
1422 $ hg up qparent
1426 $ hg up qparent
1423 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1427 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1424 $ hg qpop
1428 $ hg qpop
1425 popping empty
1429 popping empty
1426 patch queue now empty
1430 patch queue now empty
1427
1431
1428 $ cd ..
1432 $ cd ..
1429 $ hg init deletion-order
1433 $ hg init deletion-order
1430 $ cd deletion-order
1434 $ cd deletion-order
1431
1435
1432 $ touch a
1436 $ touch a
1433 $ hg ci -Aqm0
1437 $ hg ci -Aqm0
1434
1438
1435 $ hg qnew rename-dir
1439 $ hg qnew rename-dir
1436 $ hg rm a
1440 $ hg rm a
1437 $ hg qrefresh
1441 $ hg qrefresh
1438
1442
1439 $ mkdir a b
1443 $ mkdir a b
1440 $ touch a/a b/b
1444 $ touch a/a b/b
1441 $ hg add -q a b
1445 $ hg add -q a b
1442 $ hg qrefresh
1446 $ hg qrefresh
1443
1447
1444
1448
1445 test popping must remove files added in subdirectories first
1449 test popping must remove files added in subdirectories first
1446
1450
1447 $ hg qpop
1451 $ hg qpop
1448 popping rename-dir
1452 popping rename-dir
1449 patch queue now empty
1453 patch queue now empty
1450 $ cd ..
1454 $ cd ..
1451
1455
1452
1456
1453 test case preservation through patch pushing especially on case
1457 test case preservation through patch pushing especially on case
1454 insensitive filesystem
1458 insensitive filesystem
1455
1459
1456 $ hg init casepreserve
1460 $ hg init casepreserve
1457 $ cd casepreserve
1461 $ cd casepreserve
1458
1462
1459 $ hg qnew add-file1
1463 $ hg qnew add-file1
1460 $ echo a > TeXtFiLe.TxT
1464 $ echo a > TeXtFiLe.TxT
1461 $ hg add TeXtFiLe.TxT
1465 $ hg add TeXtFiLe.TxT
1462 $ hg qrefresh
1466 $ hg qrefresh
1463
1467
1464 $ hg qnew add-file2
1468 $ hg qnew add-file2
1465 $ echo b > AnOtHeRFiLe.TxT
1469 $ echo b > AnOtHeRFiLe.TxT
1466 $ hg add AnOtHeRFiLe.TxT
1470 $ hg add AnOtHeRFiLe.TxT
1467 $ hg qrefresh
1471 $ hg qrefresh
1468
1472
1469 $ hg qnew modify-file
1473 $ hg qnew modify-file
1470 $ echo c >> AnOtHeRFiLe.TxT
1474 $ echo c >> AnOtHeRFiLe.TxT
1471 $ hg qrefresh
1475 $ hg qrefresh
1472
1476
1473 $ hg qapplied
1477 $ hg qapplied
1474 add-file1
1478 add-file1
1475 add-file2
1479 add-file2
1476 modify-file
1480 modify-file
1477 $ hg qpop -a
1481 $ hg qpop -a
1478 popping modify-file
1482 popping modify-file
1479 popping add-file2
1483 popping add-file2
1480 popping add-file1
1484 popping add-file1
1481 patch queue now empty
1485 patch queue now empty
1482
1486
1483 this qpush causes problems below, if case preservation on case
1487 this qpush causes problems below, if case preservation on case
1484 insensitive filesystem is not enough:
1488 insensitive filesystem is not enough:
1485 (1) unexpected "adding ..." messages are shown
1489 (1) unexpected "adding ..." messages are shown
1486 (2) patching fails in modification of (1) files
1490 (2) patching fails in modification of (1) files
1487
1491
1488 $ hg qpush -a
1492 $ hg qpush -a
1489 applying add-file1
1493 applying add-file1
1490 applying add-file2
1494 applying add-file2
1491 applying modify-file
1495 applying modify-file
1492 now at: modify-file
1496 now at: modify-file
1493
1497
1494 Proper phase default with mq:
1498 Proper phase default with mq:
1495
1499
1496 1. mq.secret=false
1500 1. mq.secret=false
1497
1501
1498 $ rm .hg/store/phaseroots
1502 $ rm .hg/store/phaseroots
1499 $ hg phase 'qparent::'
1503 $ hg phase 'qparent::'
1500 0: draft
1504 0: draft
1501 1: draft
1505 1: draft
1502 2: draft
1506 2: draft
1503 $ echo '[mq]' >> $HGRCPATH
1507 $ echo '[mq]' >> $HGRCPATH
1504 $ echo 'secret=true' >> $HGRCPATH
1508 $ echo 'secret=true' >> $HGRCPATH
1505 $ rm -f .hg/store/phaseroots
1509 $ rm -f .hg/store/phaseroots
1506 $ hg phase 'qparent::'
1510 $ hg phase 'qparent::'
1507 0: secret
1511 0: secret
1508 1: secret
1512 1: secret
1509 2: secret
1513 2: secret
1510
1514
1511 Test that qfinish change phase when mq.secret=true
1515 Test that qfinish change phase when mq.secret=true
1512
1516
1513 $ hg qfinish qbase
1517 $ hg qfinish qbase
1514 patch add-file1 finalized without changeset message
1518 patch add-file1 finalized without changeset message
1515 $ hg phase 'all()'
1519 $ hg phase 'all()'
1516 0: draft
1520 0: draft
1517 1: secret
1521 1: secret
1518 2: secret
1522 2: secret
1519
1523
1520 Test that qfinish respect phases.new-commit setting
1524 Test that qfinish respect phases.new-commit setting
1521
1525
1522 $ echo '[phases]' >> $HGRCPATH
1526 $ echo '[phases]' >> $HGRCPATH
1523 $ echo 'new-commit=secret' >> $HGRCPATH
1527 $ echo 'new-commit=secret' >> $HGRCPATH
1524 $ hg qfinish qbase
1528 $ hg qfinish qbase
1525 patch add-file2 finalized without changeset message
1529 patch add-file2 finalized without changeset message
1526 $ hg phase 'all()'
1530 $ hg phase 'all()'
1527 0: draft
1531 0: draft
1528 1: secret
1532 1: secret
1529 2: secret
1533 2: secret
1530
1534
1531 (restore env for next test)
1535 (restore env for next test)
1532
1536
1533 $ sed -e 's/new-commit=secret//' $HGRCPATH > $TESTTMP/sedtmp
1537 $ sed -e 's/new-commit=secret//' $HGRCPATH > $TESTTMP/sedtmp
1534 $ cp $TESTTMP/sedtmp $HGRCPATH
1538 $ cp $TESTTMP/sedtmp $HGRCPATH
1535 $ hg qimport -r 1 --name add-file2
1539 $ hg qimport -r 1 --name add-file2
1536
1540
1537 Test that qfinish preserve phase when mq.secret=false
1541 Test that qfinish preserve phase when mq.secret=false
1538
1542
1539 $ sed -e 's/secret=true/secret=false/' $HGRCPATH > $TESTTMP/sedtmp
1543 $ sed -e 's/secret=true/secret=false/' $HGRCPATH > $TESTTMP/sedtmp
1540 $ cp $TESTTMP/sedtmp $HGRCPATH
1544 $ cp $TESTTMP/sedtmp $HGRCPATH
1541 $ hg qfinish qbase
1545 $ hg qfinish qbase
1542 patch add-file2 finalized without changeset message
1546 patch add-file2 finalized without changeset message
1543 $ hg phase 'all()'
1547 $ hg phase 'all()'
1544 0: draft
1548 0: draft
1545 1: secret
1549 1: secret
1546 2: secret
1550 2: secret
1547
1551
1548 $ cd ..
1552 $ cd ..
@@ -1,370 +1,373 b''
1
1
2
2
3 This test tries to exercise the ssh functionality with a dummy script
3 This test tries to exercise the ssh functionality with a dummy script
4
4
5 creating 'remote' repo
5 creating 'remote' repo
6
6
7 $ hg init remote
7 $ hg init remote
8 $ cd remote
8 $ cd remote
9 $ echo this > foo
9 $ echo this > foo
10 $ echo this > fooO
10 $ echo this > fooO
11 $ hg ci -A -m "init" foo fooO
11 $ hg ci -A -m "init" foo fooO
12 $ cat <<EOF > .hg/hgrc
12 $ cat <<EOF > .hg/hgrc
13 > [server]
13 > [server]
14 > uncompressed = True
14 > uncompressed = True
15 >
15 >
16 > [hooks]
16 > [hooks]
17 > changegroup = python "$TESTDIR"/printenv.py changegroup-in-remote 0 ../dummylog
17 > changegroup = python "$TESTDIR"/printenv.py changegroup-in-remote 0 ../dummylog
18 > EOF
18 > EOF
19 $ cd ..
19 $ cd ..
20
20
21 repo not found error
21 repo not found error
22
22
23 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/nonexistent local
23 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/nonexistent local
24 remote: abort: there is no Mercurial repository here (.hg not found)!
24 remote: abort: there is no Mercurial repository here (.hg not found)!
25 abort: no suitable response from remote hg!
25 abort: no suitable response from remote hg!
26 [255]
26 [255]
27
27
28 non-existent absolute path
28 non-existent absolute path
29
29
30 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy//`pwd`/nonexistent local
30 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy//`pwd`/nonexistent local
31 remote: abort: there is no Mercurial repository here (.hg not found)!
31 remote: abort: there is no Mercurial repository here (.hg not found)!
32 abort: no suitable response from remote hg!
32 abort: no suitable response from remote hg!
33 [255]
33 [255]
34
34
35 clone remote via stream
35 clone remote via stream
36
36
37 $ hg clone -e "python \"$TESTDIR/dummyssh\"" --uncompressed ssh://user@dummy/remote local-stream
37 $ hg clone -e "python \"$TESTDIR/dummyssh\"" --uncompressed ssh://user@dummy/remote local-stream
38 streaming all changes
38 streaming all changes
39 4 files to transfer, 392 bytes of data
39 4 files to transfer, 392 bytes of data
40 transferred 392 bytes in * seconds (*/sec) (glob)
40 transferred 392 bytes in * seconds (*/sec) (glob)
41 updating to branch default
41 updating to branch default
42 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
42 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
43 $ cd local-stream
43 $ cd local-stream
44 $ hg verify
44 $ hg verify
45 checking changesets
45 checking changesets
46 checking manifests
46 checking manifests
47 crosschecking files in changesets and manifests
47 crosschecking files in changesets and manifests
48 checking files
48 checking files
49 2 files, 1 changesets, 2 total revisions
49 2 files, 1 changesets, 2 total revisions
50 $ cd ..
50 $ cd ..
51
51
52 clone remote via pull
52 clone remote via pull
53
53
54 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote local
54 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote local
55 requesting all changes
55 requesting all changes
56 adding changesets
56 adding changesets
57 adding manifests
57 adding manifests
58 adding file changes
58 adding file changes
59 added 1 changesets with 2 changes to 2 files
59 added 1 changesets with 2 changes to 2 files
60 updating to branch default
60 updating to branch default
61 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
61 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
62
62
63 verify
63 verify
64
64
65 $ cd local
65 $ cd local
66 $ hg verify
66 $ hg verify
67 checking changesets
67 checking changesets
68 checking manifests
68 checking manifests
69 crosschecking files in changesets and manifests
69 crosschecking files in changesets and manifests
70 checking files
70 checking files
71 2 files, 1 changesets, 2 total revisions
71 2 files, 1 changesets, 2 total revisions
72 $ echo '[hooks]' >> .hg/hgrc
72 $ echo '[hooks]' >> .hg/hgrc
73 $ echo 'changegroup = python "$TESTDIR"/printenv.py changegroup-in-local 0 ../dummylog' >> .hg/hgrc
73 $ echo 'changegroup = python "$TESTDIR"/printenv.py changegroup-in-local 0 ../dummylog' >> .hg/hgrc
74
74
75 empty default pull
75 empty default pull
76
76
77 $ hg paths
77 $ hg paths
78 default = ssh://user@dummy/remote
78 default = ssh://user@dummy/remote
79 $ hg pull -e "python \"$TESTDIR/dummyssh\""
79 $ hg pull -e "python \"$TESTDIR/dummyssh\""
80 pulling from ssh://user@dummy/remote
80 pulling from ssh://user@dummy/remote
81 searching for changes
81 searching for changes
82 no changes found
82 no changes found
83
83
84 local change
84 local change
85
85
86 $ echo bleah > foo
86 $ echo bleah > foo
87 $ hg ci -m "add"
87 $ hg ci -m "add"
88
88
89 updating rc
89 updating rc
90
90
91 $ echo "default-push = ssh://user@dummy/remote" >> .hg/hgrc
91 $ echo "default-push = ssh://user@dummy/remote" >> .hg/hgrc
92 $ echo "[ui]" >> .hg/hgrc
92 $ echo "[ui]" >> .hg/hgrc
93 $ echo "ssh = python \"$TESTDIR/dummyssh\"" >> .hg/hgrc
93 $ echo "ssh = python \"$TESTDIR/dummyssh\"" >> .hg/hgrc
94
94
95 find outgoing
95 find outgoing
96
96
97 $ hg out ssh://user@dummy/remote
97 $ hg out ssh://user@dummy/remote
98 comparing with ssh://user@dummy/remote
98 comparing with ssh://user@dummy/remote
99 searching for changes
99 searching for changes
100 changeset: 1:a28a9d1a809c
100 changeset: 1:a28a9d1a809c
101 tag: tip
101 tag: tip
102 user: test
102 user: test
103 date: Thu Jan 01 00:00:00 1970 +0000
103 date: Thu Jan 01 00:00:00 1970 +0000
104 summary: add
104 summary: add
105
105
106
106
107 find incoming on the remote side
107 find incoming on the remote side
108
108
109 $ hg incoming -R ../remote -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/local
109 $ hg incoming -R ../remote -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/local
110 comparing with ssh://user@dummy/local
110 comparing with ssh://user@dummy/local
111 searching for changes
111 searching for changes
112 changeset: 1:a28a9d1a809c
112 changeset: 1:a28a9d1a809c
113 tag: tip
113 tag: tip
114 user: test
114 user: test
115 date: Thu Jan 01 00:00:00 1970 +0000
115 date: Thu Jan 01 00:00:00 1970 +0000
116 summary: add
116 summary: add
117
117
118
118
119 find incoming on the remote side (using absolute path)
119 find incoming on the remote side (using absolute path)
120
120
121 $ hg incoming -R ../remote -e "python \"$TESTDIR/dummyssh\"" "ssh://user@dummy/`pwd`"
121 $ hg incoming -R ../remote -e "python \"$TESTDIR/dummyssh\"" "ssh://user@dummy/`pwd`"
122 comparing with ssh://user@dummy/$TESTTMP/local
122 comparing with ssh://user@dummy/$TESTTMP/local
123 searching for changes
123 searching for changes
124 changeset: 1:a28a9d1a809c
124 changeset: 1:a28a9d1a809c
125 tag: tip
125 tag: tip
126 user: test
126 user: test
127 date: Thu Jan 01 00:00:00 1970 +0000
127 date: Thu Jan 01 00:00:00 1970 +0000
128 summary: add
128 summary: add
129
129
130
130
131 push
131 push
132
132
133 $ hg push
133 $ hg push
134 pushing to ssh://user@dummy/remote
134 pushing to ssh://user@dummy/remote
135 searching for changes
135 searching for changes
136 remote: adding changesets
136 remote: adding changesets
137 remote: adding manifests
137 remote: adding manifests
138 remote: adding file changes
138 remote: adding file changes
139 remote: added 1 changesets with 1 changes to 1 files
139 remote: added 1 changesets with 1 changes to 1 files
140 $ cd ../remote
140 $ cd ../remote
141
141
142 check remote tip
142 check remote tip
143
143
144 $ hg tip
144 $ hg tip
145 changeset: 1:a28a9d1a809c
145 changeset: 1:a28a9d1a809c
146 tag: tip
146 tag: tip
147 user: test
147 user: test
148 date: Thu Jan 01 00:00:00 1970 +0000
148 date: Thu Jan 01 00:00:00 1970 +0000
149 summary: add
149 summary: add
150
150
151 $ hg verify
151 $ hg verify
152 checking changesets
152 checking changesets
153 checking manifests
153 checking manifests
154 crosschecking files in changesets and manifests
154 crosschecking files in changesets and manifests
155 checking files
155 checking files
156 2 files, 2 changesets, 3 total revisions
156 2 files, 2 changesets, 3 total revisions
157 $ hg cat -r tip foo
157 $ hg cat -r tip foo
158 bleah
158 bleah
159 $ echo z > z
159 $ echo z > z
160 $ hg ci -A -m z z
160 $ hg ci -A -m z z
161 created new head
161 created new head
162
162
163 test pushkeys and bookmarks
163 test pushkeys and bookmarks
164
164
165 $ cd ../local
165 $ cd ../local
166 $ hg debugpushkey --config ui.ssh="python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote namespaces
166 $ hg debugpushkey --config ui.ssh="python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote namespaces
167 bookmarks
167 bookmarks
168 phases
168 phases
169 namespaces
169 namespaces
170 $ hg book foo -r 0
170 $ hg book foo -r 0
171 $ hg out -B
171 $ hg out -B
172 comparing with ssh://user@dummy/remote
172 comparing with ssh://user@dummy/remote
173 searching for changed bookmarks
173 searching for changed bookmarks
174 foo 1160648e36ce
174 foo 1160648e36ce
175 $ hg push -B foo
175 $ hg push -B foo
176 pushing to ssh://user@dummy/remote
176 pushing to ssh://user@dummy/remote
177 searching for changes
177 searching for changes
178 no changes found
178 no changes found
179 exporting bookmark foo
179 exporting bookmark foo
180 [1]
180 [1]
181 $ hg debugpushkey --config ui.ssh="python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote bookmarks
181 $ hg debugpushkey --config ui.ssh="python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote bookmarks
182 foo 1160648e36cec0054048a7edc4110c6f84fde594
182 foo 1160648e36cec0054048a7edc4110c6f84fde594
183 $ hg book -f foo
183 $ hg book -f foo
184 $ hg push --traceback
184 $ hg push --traceback
185 pushing to ssh://user@dummy/remote
185 pushing to ssh://user@dummy/remote
186 searching for changes
186 searching for changes
187 no changes found
187 no changes found
188 updating bookmark foo
188 updating bookmark foo
189 [1]
189 [1]
190 $ hg book -d foo
190 $ hg book -d foo
191 $ hg in -B
191 $ hg in -B
192 comparing with ssh://user@dummy/remote
192 comparing with ssh://user@dummy/remote
193 searching for changed bookmarks
193 searching for changed bookmarks
194 foo a28a9d1a809c
194 foo a28a9d1a809c
195 $ hg book -f -r 0 foo
195 $ hg book -f -r 0 foo
196 $ hg pull -B foo
196 $ hg pull -B foo
197 pulling from ssh://user@dummy/remote
197 pulling from ssh://user@dummy/remote
198 no changes found
198 no changes found
199 updating bookmark foo
199 updating bookmark foo
200 importing bookmark foo
200 importing bookmark foo
201 $ hg book -d foo
201 $ hg book -d foo
202 $ hg push -B foo
202 $ hg push -B foo
203 pushing to ssh://user@dummy/remote
203 pushing to ssh://user@dummy/remote
204 searching for changes
204 searching for changes
205 no changes found
205 no changes found
206 deleting remote bookmark foo
206 deleting remote bookmark foo
207 [1]
207 [1]
208
208
209 a bad, evil hook that prints to stdout
209 a bad, evil hook that prints to stdout
210
210
211 $ cat <<EOF > $TESTTMP/badhook
211 $ cat <<EOF > $TESTTMP/badhook
212 > import sys
212 > import sys
213 > sys.stdout.write("KABOOM\n")
213 > sys.stdout.write("KABOOM\n")
214 > EOF
214 > EOF
215
215
216 $ echo '[hooks]' >> ../remote/.hg/hgrc
216 $ echo '[hooks]' >> ../remote/.hg/hgrc
217 $ echo "changegroup.stdout = python $TESTTMP/badhook" >> ../remote/.hg/hgrc
217 $ echo "changegroup.stdout = python $TESTTMP/badhook" >> ../remote/.hg/hgrc
218 $ echo r > r
218 $ echo r > r
219 $ hg ci -A -m z r
219 $ hg ci -A -m z r
220
220
221 push should succeed even though it has an unexpected response
221 push should succeed even though it has an unexpected response
222
222
223 $ hg push
223 $ hg push
224 pushing to ssh://user@dummy/remote
224 pushing to ssh://user@dummy/remote
225 searching for changes
225 searching for changes
226 note: unsynced remote changes!
226 note: unsynced remote changes!
227 remote: adding changesets
227 remote: adding changesets
228 remote: adding manifests
228 remote: adding manifests
229 remote: adding file changes
229 remote: adding file changes
230 remote: added 1 changesets with 1 changes to 1 files
230 remote: added 1 changesets with 1 changes to 1 files
231 remote: KABOOM
231 remote: KABOOM
232 $ hg -R ../remote heads
232 $ hg -R ../remote heads
233 changeset: 3:1383141674ec
233 changeset: 3:1383141674ec
234 tag: tip
234 tag: tip
235 parent: 1:a28a9d1a809c
235 parent: 1:a28a9d1a809c
236 user: test
236 user: test
237 date: Thu Jan 01 00:00:00 1970 +0000
237 date: Thu Jan 01 00:00:00 1970 +0000
238 summary: z
238 summary: z
239
239
240 changeset: 2:6c0482d977a3
240 changeset: 2:6c0482d977a3
241 parent: 0:1160648e36ce
241 parent: 0:1160648e36ce
242 user: test
242 user: test
243 date: Thu Jan 01 00:00:00 1970 +0000
243 date: Thu Jan 01 00:00:00 1970 +0000
244 summary: z
244 summary: z
245
245
246
246
247 clone bookmarks
247 clone bookmarks
248
248
249 $ hg -R ../remote bookmark test
249 $ hg -R ../remote bookmark test
250 $ hg -R ../remote bookmarks
250 $ hg -R ../remote bookmarks
251 * test 2:6c0482d977a3
251 * test 2:6c0482d977a3
252 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote local-bookmarks
252 $ hg clone -e "python \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote local-bookmarks
253 requesting all changes
253 requesting all changes
254 adding changesets
254 adding changesets
255 adding manifests
255 adding manifests
256 adding file changes
256 adding file changes
257 added 4 changesets with 5 changes to 4 files (+1 heads)
257 added 4 changesets with 5 changes to 4 files (+1 heads)
258 updating to branch default
258 updating to branch default
259 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
259 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
260 $ hg -R local-bookmarks bookmarks
260 $ hg -R local-bookmarks bookmarks
261 test 2:6c0482d977a3
261 test 2:6c0482d977a3
262
262
263 passwords in ssh urls are not supported
263 passwords in ssh urls are not supported
264 (we use a glob here because different Python versions give different
264 (we use a glob here because different Python versions give different
265 results here)
265 results here)
266
266
267 $ hg push ssh://user:erroneouspwd@dummy/remote
267 $ hg push ssh://user:erroneouspwd@dummy/remote
268 pushing to ssh://user:*@dummy/remote (glob)
268 pushing to ssh://user:*@dummy/remote (glob)
269 abort: password in URL not supported!
269 abort: password in URL not supported!
270 [255]
270 [255]
271
271
272 $ cd ..
272 $ cd ..
273
273
274 hide outer repo
275 $ hg init
276
274 Test remote paths with spaces (issue2983):
277 Test remote paths with spaces (issue2983):
275
278
276 $ hg init --ssh "python \"$TESTDIR/dummyssh\"" "ssh://user@dummy/a repo"
279 $ hg init --ssh "python \"$TESTDIR/dummyssh\"" "ssh://user@dummy/a repo"
277 $ hg -R 'a repo' tag tag
280 $ hg -R 'a repo' tag tag
278 $ hg id --ssh "python \"$TESTDIR/dummyssh\"" "ssh://user@dummy/a repo"
281 $ hg id --ssh "python \"$TESTDIR/dummyssh\"" "ssh://user@dummy/a repo"
279 3fb238f49e8c
282 3fb238f49e8c
280
283
281 Test hg-ssh using a helper script that will restore PYTHONPATH (which might
284 Test hg-ssh using a helper script that will restore PYTHONPATH (which might
282 have been cleared by a hg.exe wrapper) and invoke hg-ssh with the right
285 have been cleared by a hg.exe wrapper) and invoke hg-ssh with the right
283 parameters:
286 parameters:
284
287
285 $ cat > ssh.sh << EOF
288 $ cat > ssh.sh << EOF
286 > userhost="\$1"
289 > userhost="\$1"
287 > SSH_ORIGINAL_COMMAND="\$2"
290 > SSH_ORIGINAL_COMMAND="\$2"
288 > export SSH_ORIGINAL_COMMAND
291 > export SSH_ORIGINAL_COMMAND
289 > PYTHONPATH="$PYTHONPATH"
292 > PYTHONPATH="$PYTHONPATH"
290 > export PYTHONPATH
293 > export PYTHONPATH
291 > python "$TESTDIR/../contrib/hg-ssh" "$TESTTMP/a repo"
294 > python "$TESTDIR/../contrib/hg-ssh" "$TESTTMP/a repo"
292 > EOF
295 > EOF
293
296
294 $ hg id --ssh "sh ssh.sh" "ssh://user@dummy/a repo"
297 $ hg id --ssh "sh ssh.sh" "ssh://user@dummy/a repo"
295 3fb238f49e8c
298 3fb238f49e8c
296
299
297 $ hg id --ssh "sh ssh.sh" "ssh://user@dummy/a'repo"
300 $ hg id --ssh "sh ssh.sh" "ssh://user@dummy/a'repo"
298 remote: Illegal repository "$TESTTMP/a'repo" (glob)
301 remote: Illegal repository "$TESTTMP/a'repo" (glob)
299 abort: no suitable response from remote hg!
302 abort: no suitable response from remote hg!
300 [255]
303 [255]
301
304
302 $ hg id --ssh "sh ssh.sh" --remotecmd hacking "ssh://user@dummy/a'repo"
305 $ hg id --ssh "sh ssh.sh" --remotecmd hacking "ssh://user@dummy/a'repo"
303 remote: Illegal command "hacking -R 'a'\''repo' serve --stdio"
306 remote: Illegal command "hacking -R 'a'\''repo' serve --stdio"
304 abort: no suitable response from remote hg!
307 abort: no suitable response from remote hg!
305 [255]
308 [255]
306
309
307 $ SSH_ORIGINAL_COMMAND="'hg' -R 'a'repo' serve --stdio" python "$TESTDIR/../contrib/hg-ssh"
310 $ SSH_ORIGINAL_COMMAND="'hg' -R 'a'repo' serve --stdio" python "$TESTDIR/../contrib/hg-ssh"
308 Illegal command "'hg' -R 'a'repo' serve --stdio": No closing quotation
311 Illegal command "'hg' -R 'a'repo' serve --stdio": No closing quotation
309 [255]
312 [255]
310
313
311 Test hg-ssh in read-only mode:
314 Test hg-ssh in read-only mode:
312
315
313 $ cat > ssh.sh << EOF
316 $ cat > ssh.sh << EOF
314 > userhost="\$1"
317 > userhost="\$1"
315 > SSH_ORIGINAL_COMMAND="\$2"
318 > SSH_ORIGINAL_COMMAND="\$2"
316 > export SSH_ORIGINAL_COMMAND
319 > export SSH_ORIGINAL_COMMAND
317 > PYTHONPATH="$PYTHONPATH"
320 > PYTHONPATH="$PYTHONPATH"
318 > export PYTHONPATH
321 > export PYTHONPATH
319 > python "$TESTDIR/../contrib/hg-ssh" --read-only "$TESTTMP/remote"
322 > python "$TESTDIR/../contrib/hg-ssh" --read-only "$TESTTMP/remote"
320 > EOF
323 > EOF
321
324
322 $ hg clone --ssh "sh ssh.sh" "ssh://user@dummy/$TESTTMP/remote" read-only-local
325 $ hg clone --ssh "sh ssh.sh" "ssh://user@dummy/$TESTTMP/remote" read-only-local
323 requesting all changes
326 requesting all changes
324 adding changesets
327 adding changesets
325 adding manifests
328 adding manifests
326 adding file changes
329 adding file changes
327 added 4 changesets with 5 changes to 4 files (+1 heads)
330 added 4 changesets with 5 changes to 4 files (+1 heads)
328 updating to branch default
331 updating to branch default
329 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
332 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
330
333
331 $ cd read-only-local
334 $ cd read-only-local
332 $ echo "baz" > bar
335 $ echo "baz" > bar
333 $ hg ci -A -m "unpushable commit" bar
336 $ hg ci -A -m "unpushable commit" bar
334 $ hg push --ssh "sh ../ssh.sh"
337 $ hg push --ssh "sh ../ssh.sh"
335 pushing to ssh://user@dummy/*/remote (glob)
338 pushing to ssh://user@dummy/*/remote (glob)
336 searching for changes
339 searching for changes
337 remote: Permission denied
340 remote: Permission denied
338 remote: abort: prechangegroup.hg-ssh hook failed
341 remote: abort: prechangegroup.hg-ssh hook failed
339 remote: Permission denied
342 remote: Permission denied
340 remote: abort: prepushkey.hg-ssh hook failed
343 remote: abort: prepushkey.hg-ssh hook failed
341 abort: unexpected response: empty string
344 abort: unexpected response: empty string
342 [255]
345 [255]
343
346
344 $ cd ..
347 $ cd ..
345
348
346 $ cat dummylog
349 $ cat dummylog
347 Got arguments 1:user@dummy 2:hg -R nonexistent serve --stdio
350 Got arguments 1:user@dummy 2:hg -R nonexistent serve --stdio
348 Got arguments 1:user@dummy 2:hg -R /$TESTTMP/nonexistent serve --stdio
351 Got arguments 1:user@dummy 2:hg -R /$TESTTMP/nonexistent serve --stdio
349 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
352 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
350 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
353 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
351 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
354 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
352 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
355 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
353 Got arguments 1:user@dummy 2:hg -R local serve --stdio
356 Got arguments 1:user@dummy 2:hg -R local serve --stdio
354 Got arguments 1:user@dummy 2:hg -R $TESTTMP/local serve --stdio
357 Got arguments 1:user@dummy 2:hg -R $TESTTMP/local serve --stdio
355 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
358 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
356 changegroup-in-remote hook: HG_NODE=a28a9d1a809cab7d4e2fde4bee738a9ede948b60 HG_SOURCE=serve HG_URL=remote:ssh:127.0.0.1
359 changegroup-in-remote hook: HG_NODE=a28a9d1a809cab7d4e2fde4bee738a9ede948b60 HG_SOURCE=serve HG_URL=remote:ssh:127.0.0.1
357 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
360 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
358 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
361 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
359 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
362 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
360 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
363 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
361 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
364 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
362 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
365 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
363 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
366 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
364 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
367 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
365 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
368 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
366 changegroup-in-remote hook: HG_NODE=1383141674ec756a6056f6a9097618482fe0f4a6 HG_SOURCE=serve HG_URL=remote:ssh:127.0.0.1
369 changegroup-in-remote hook: HG_NODE=1383141674ec756a6056f6a9097618482fe0f4a6 HG_SOURCE=serve HG_URL=remote:ssh:127.0.0.1
367 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
370 Got arguments 1:user@dummy 2:hg -R remote serve --stdio
368 Got arguments 1:user@dummy 2:hg init 'a repo'
371 Got arguments 1:user@dummy 2:hg init 'a repo'
369 Got arguments 1:user@dummy 2:hg -R 'a repo' serve --stdio
372 Got arguments 1:user@dummy 2:hg -R 'a repo' serve --stdio
370 Got arguments 1:user@dummy 2:hg -R 'a repo' serve --stdio
373 Got arguments 1:user@dummy 2:hg -R 'a repo' serve --stdio
@@ -1,105 +1,108 b''
1 $ "$TESTDIR/hghave" serve || exit 80
1 $ "$TESTDIR/hghave" serve || exit 80
2
2
3 Preparing the subrepository 'sub'
3 Preparing the subrepository 'sub'
4
4
5 $ hg init sub
5 $ hg init sub
6 $ echo sub > sub/sub
6 $ echo sub > sub/sub
7 $ hg add -R sub
7 $ hg add -R sub
8 adding sub/sub (glob)
8 adding sub/sub (glob)
9 $ hg commit -R sub -m "sub import"
9 $ hg commit -R sub -m "sub import"
10
10
11 Preparing the 'main' repo which depends on the subrepo 'sub'
11 Preparing the 'main' repo which depends on the subrepo 'sub'
12
12
13 $ hg init main
13 $ hg init main
14 $ echo main > main/main
14 $ echo main > main/main
15 $ echo "sub = ../sub" > main/.hgsub
15 $ echo "sub = ../sub" > main/.hgsub
16 $ hg clone sub main/sub
16 $ hg clone sub main/sub
17 updating to branch default
17 updating to branch default
18 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
18 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
19 $ hg add -R main
19 $ hg add -R main
20 adding main/.hgsub (glob)
20 adding main/.hgsub (glob)
21 adding main/main (glob)
21 adding main/main (glob)
22 $ hg commit -R main -m "main import"
22 $ hg commit -R main -m "main import"
23
23
24 Cleaning both repositories, just as a clone -U
24 Cleaning both repositories, just as a clone -U
25
25
26 $ hg up -C -R sub null
26 $ hg up -C -R sub null
27 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
27 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
28 $ hg up -C -R main null
28 $ hg up -C -R main null
29 0 files updated, 0 files merged, 3 files removed, 0 files unresolved
29 0 files updated, 0 files merged, 3 files removed, 0 files unresolved
30 $ rm -rf main/sub
30 $ rm -rf main/sub
31
31
32 hide outer repo
33 $ hg init
34
32 Serving them both using hgweb
35 Serving them both using hgweb
33
36
34 $ printf '[paths]\n/main = main\nsub = sub\n' > webdir.conf
37 $ printf '[paths]\n/main = main\nsub = sub\n' > webdir.conf
35 $ hg serve --webdir-conf webdir.conf -a localhost -p $HGPORT \
38 $ hg serve --webdir-conf webdir.conf -a localhost -p $HGPORT \
36 > -A /dev/null -E /dev/null --pid-file hg.pid -d
39 > -A /dev/null -E /dev/null --pid-file hg.pid -d
37 $ cat hg.pid >> $DAEMON_PIDS
40 $ cat hg.pid >> $DAEMON_PIDS
38
41
39 Clone main from hgweb
42 Clone main from hgweb
40
43
41 $ hg clone "http://localhost:$HGPORT/main" cloned
44 $ hg clone "http://localhost:$HGPORT/main" cloned
42 requesting all changes
45 requesting all changes
43 adding changesets
46 adding changesets
44 adding manifests
47 adding manifests
45 adding file changes
48 adding file changes
46 added 1 changesets with 3 changes to 3 files
49 added 1 changesets with 3 changes to 3 files
47 updating to branch default
50 updating to branch default
48 cloning subrepo sub from http://localhost:$HGPORT/sub
51 cloning subrepo sub from http://localhost:$HGPORT/sub
49 requesting all changes
52 requesting all changes
50 adding changesets
53 adding changesets
51 adding manifests
54 adding manifests
52 adding file changes
55 adding file changes
53 added 1 changesets with 1 changes to 1 files
56 added 1 changesets with 1 changes to 1 files
54 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
57 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
55
58
56 Checking cloned repo ids
59 Checking cloned repo ids
57
60
58 $ hg id -R cloned
61 $ hg id -R cloned
59 fdfeeb3e979e tip
62 fdfeeb3e979e tip
60 $ hg id -R cloned/sub
63 $ hg id -R cloned/sub
61 863c1745b441 tip
64 863c1745b441 tip
62
65
63 subrepo debug for 'main' clone
66 subrepo debug for 'main' clone
64
67
65 $ hg debugsub -R cloned
68 $ hg debugsub -R cloned
66 path sub
69 path sub
67 source ../sub
70 source ../sub
68 revision 863c1745b441bd97a8c4a096e87793073f4fb215
71 revision 863c1745b441bd97a8c4a096e87793073f4fb215
69
72
70 $ "$TESTDIR/killdaemons.py"
73 $ "$TESTDIR/killdaemons.py"
71
74
72 subrepo paths with ssh urls
75 subrepo paths with ssh urls
73
76
74 $ cp "$TESTDIR/dummyssh" "$BINDIR/ssh"
77 $ cp "$TESTDIR/dummyssh" "$BINDIR/ssh"
75
78
76 $ hg clone ssh://user@dummy/cloned sshclone
79 $ hg clone ssh://user@dummy/cloned sshclone
77 requesting all changes
80 requesting all changes
78 adding changesets
81 adding changesets
79 adding manifests
82 adding manifests
80 adding file changes
83 adding file changes
81 added 1 changesets with 3 changes to 3 files
84 added 1 changesets with 3 changes to 3 files
82 updating to branch default
85 updating to branch default
83 cloning subrepo sub from ssh://user@dummy/sub
86 cloning subrepo sub from ssh://user@dummy/sub
84 requesting all changes
87 requesting all changes
85 adding changesets
88 adding changesets
86 adding manifests
89 adding manifests
87 adding file changes
90 adding file changes
88 added 1 changesets with 1 changes to 1 files
91 added 1 changesets with 1 changes to 1 files
89 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
92 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
90
93
91 $ hg -R sshclone push ssh://user@dummy/$TESTTMP/cloned
94 $ hg -R sshclone push ssh://user@dummy/$TESTTMP/cloned
92 pushing to ssh://user@dummy/$TESTTMP/cloned
95 pushing to ssh://user@dummy/$TESTTMP/cloned
93 pushing subrepo sub to ssh://user@dummy/$TESTTMP/sub
96 pushing subrepo sub to ssh://user@dummy/$TESTTMP/sub
94 searching for changes
97 searching for changes
95 no changes found
98 no changes found
96 searching for changes
99 searching for changes
97 no changes found
100 no changes found
98 [1]
101 [1]
99
102
100 $ cat dummylog
103 $ cat dummylog
101 Got arguments 1:user@dummy 2:hg -R cloned serve --stdio
104 Got arguments 1:user@dummy 2:hg -R cloned serve --stdio
102 Got arguments 1:user@dummy 2:hg -R sub serve --stdio
105 Got arguments 1:user@dummy 2:hg -R sub serve --stdio
103 Got arguments 1:user@dummy 2:hg -R $TESTTMP/cloned serve --stdio
106 Got arguments 1:user@dummy 2:hg -R $TESTTMP/cloned serve --stdio
104 Got arguments 1:user@dummy 2:hg -R $TESTTMP/sub serve --stdio
107 Got arguments 1:user@dummy 2:hg -R $TESTTMP/sub serve --stdio
105 $ rm "$BINDIR/ssh"
108 $ rm "$BINDIR/ssh"
General Comments 0
You need to be logged in to leave comments. Login now