Show More
@@ -292,6 +292,25 b' Status between revisions:' | |||
|
292 | 292 | z2 |
|
293 | 293 | z3 |
|
294 | 294 | |
|
295 | BUG: The remote subrepo should be cloned to the local pool, and then shared | |
|
296 | from there. | |
|
297 | ||
|
298 | $ hg --config extensions.share= --config share.pool=$TESTTMP/pool \ | |
|
299 | > clone http://localhost:$HGPORT shared | |
|
300 | (sharing from new pooled repository 23376cbba0d87c15906bb3652584927c140907bf) | |
|
301 | requesting all changes | |
|
302 | adding changesets | |
|
303 | adding manifests | |
|
304 | adding file changes | |
|
305 | added 3 changesets with 5 changes to 3 files | |
|
306 | new changesets 23376cbba0d8:1326fa26d0c0 | |
|
307 | searching for changes | |
|
308 | no changes found | |
|
309 | updating working directory | |
|
310 | sharing subrepo foo from http://localhost:$HGPORT/foo | |
|
311 | abort: can only share local repositories (in subrepository "foo") | |
|
312 | [255] | |
|
313 | ||
|
295 | 314 | $ cat access.log |
|
296 | 315 | * "GET /?cmd=capabilities HTTP/1.1" 200 - (glob) |
|
297 | 316 | * "GET /?cmd=batch HTTP/1.1" 200 - * (glob) |
@@ -302,6 +321,14 b' Status between revisions:' | |||
|
302 | 321 | * "GET /foo/bar?cmd=capabilities HTTP/1.1" 200 - (glob) |
|
303 | 322 | * "GET /foo/bar?cmd=batch HTTP/1.1" 200 - * (glob) |
|
304 | 323 | * "GET /foo/bar?cmd=getbundle HTTP/1.1" 200 - * (glob) |
|
324 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=capabilities HTTP/1.1" 200 - (glob) | |
|
325 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=lookup HTTP/1.1" 200 - x-hgarg-1:key=0 x-hgproto-1:0.1 0.2 comp=$USUAL_COMPRESSIONS$ (glob) | |
|
326 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=capabilities HTTP/1.1" 200 - (glob) | |
|
327 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=batch HTTP/1.1" 200 - x-hgarg-1:cmds=heads+%3Bknown+nodes%3D x-hgproto-1:0.1 0.2 comp=$USUAL_COMPRESSIONS$ (glob) | |
|
328 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=getbundle HTTP/1.1" 200 - x-hgarg-1:bookmarks=1&$USUAL_BUNDLE_CAPS$&cg=1&common=0000000000000000000000000000000000000000&heads=1326fa26d0c00d2146c63b56bb6a45149d7325ac&listkeys=bookmarks&phases=1 x-hgproto-1:0.1 0.2 comp=$USUAL_COMPRESSIONS$ (glob) | |
|
329 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=batch HTTP/1.1" 200 - x-hgarg-1:cmds=heads+%3Bknown+nodes%3D1326fa26d0c00d2146c63b56bb6a45149d7325ac x-hgproto-1:0.1 0.2 comp=$USUAL_COMPRESSIONS$ (glob) | |
|
330 | $LOCALIP - - [$LOGDATE$] "GET /?cmd=getbundle HTTP/1.1" 200 - x-hgarg-1:bookmarks=1&$USUAL_BUNDLE_CAPS$&cg=0&common=1326fa26d0c00d2146c63b56bb6a45149d7325ac&heads=1326fa26d0c00d2146c63b56bb6a45149d7325ac&listkeys=bookmarks&phases=1 x-hgproto-1:0.1 0.2 comp=$USUAL_COMPRESSIONS$ (glob) | |
|
331 | $LOCALIP - - [$LOGDATE$] "GET /foo?cmd=capabilities HTTP/1.1" 200 - (glob) | |
|
305 | 332 | |
|
306 | 333 | $ killdaemons.py |
|
307 | 334 | $ rm hg1.pid error.log access.log |
@@ -485,6 +512,22 b' The newly cloned subrepos contain no wor' | |||
|
485 | 512 | commit: (clean) |
|
486 | 513 | update: 4 new changesets (update) |
|
487 | 514 | |
|
515 | Sharing a local repo without the locally referenced subrepo (i.e. it was never | |
|
516 | updated from null), fails the same as a clone operation. | |
|
517 | ||
|
518 | $ hg --config progress.disable=True clone -U ../empty ../empty2 | |
|
519 | ||
|
520 | $ hg --config extensions.share= --config progress.disable=True \ | |
|
521 | > share ../empty2 ../empty_share | |
|
522 | updating working directory | |
|
523 | abort: repository $TESTTMP/empty2/foo not found! | |
|
524 | [255] | |
|
525 | ||
|
526 | $ hg --config progress.disable=True clone ../empty2 ../empty_clone | |
|
527 | updating to branch default | |
|
528 | abort: repository $TESTTMP/empty2/foo not found! | |
|
529 | [255] | |
|
530 | ||
|
488 | 531 | Disable progress extension and cleanup: |
|
489 | 532 | |
|
490 | 533 | $ mv $HGRCPATH.no-progress $HGRCPATH |
@@ -72,6 +72,59 b" subrepo debug for 'main' clone" | |||
|
72 | 72 | source ../sub |
|
73 | 73 | revision 863c1745b441bd97a8c4a096e87793073f4fb215 |
|
74 | 74 | |
|
75 | Test sharing with a remote URL reference | |
|
76 | ||
|
77 | $ hg init absolute_subrepo | |
|
78 | $ cd absolute_subrepo | |
|
79 | $ echo foo > foo.txt | |
|
80 | $ hg ci -Am 'initial commit' | |
|
81 | adding foo.txt | |
|
82 | $ echo "sub = http://localhost:$HGPORT/sub" > .hgsub | |
|
83 | $ hg ci -Am 'add absolute subrepo' | |
|
84 | adding .hgsub | |
|
85 | $ cd .. | |
|
86 | ||
|
87 | BUG: Remote subrepos cannot be shared, and pooled repos don't have their | |
|
88 | relative subrepos in the relative location stated in .hgsub. | |
|
89 | ||
|
90 | $ hg --config extensions.share= --config share.pool=$TESTTMP/pool \ | |
|
91 | > clone absolute_subrepo cloned_from_abs | |
|
92 | (sharing from new pooled repository 8d6a2f1e993b34b6557de0042cfe825ae12a8dae) | |
|
93 | requesting all changes | |
|
94 | adding changesets | |
|
95 | adding manifests | |
|
96 | adding file changes | |
|
97 | added 2 changesets with 3 changes to 3 files | |
|
98 | new changesets 8d6a2f1e993b:c6d0e6ebd1c9 | |
|
99 | searching for changes | |
|
100 | no changes found | |
|
101 | updating working directory | |
|
102 | sharing subrepo sub from http://localhost:$HGPORT/sub | |
|
103 | abort: can only share local repositories (in subrepository "sub") | |
|
104 | [255] | |
|
105 | ||
|
106 | $ hg --config extensions.share= share absolute_subrepo shared_from_abs | |
|
107 | updating working directory | |
|
108 | sharing subrepo sub from http://localhost:$HGPORT/sub | |
|
109 | abort: can only share local repositories (in subrepository "sub") | |
|
110 | [255] | |
|
111 | ||
|
112 | $ hg --config extensions.share= share -U absolute_subrepo shared_from_abs2 | |
|
113 | $ hg -R shared_from_abs2 update -r tip | |
|
114 | sharing subrepo sub from http://localhost:$HGPORT/sub | |
|
115 | abort: can only share local repositories (in subrepository "sub") | |
|
116 | [255] | |
|
117 | ||
|
118 | BUG: A repo without its subrepo available locally should be sharable if the | |
|
119 | subrepo is referenced by absolute path. | |
|
120 | ||
|
121 | $ hg clone -U absolute_subrepo cloned_null_from_abs | |
|
122 | $ hg --config extensions.share= share cloned_null_from_abs shared_from_null_abs | |
|
123 | updating working directory | |
|
124 | sharing subrepo sub from http://localhost:$HGPORT/sub | |
|
125 | abort: can only share local repositories (in subrepository "sub") | |
|
126 | [255] | |
|
127 | ||
|
75 | 128 | $ killdaemons.py |
|
76 | 129 | |
|
77 | 130 | subrepo paths with ssh urls |
General Comments 0
You need to be logged in to leave comments.
Login now