Show More
@@ -1,119 +1,119 b'' | |||||
1 | Preparing the subrepository 'sub2' |
|
1 | Preparing the subrepository 'sub2' | |
2 |
|
2 | |||
3 | $ hg init sub2 |
|
3 | $ hg init sub2 | |
4 | $ echo sub2 > sub2/sub2 |
|
4 | $ echo sub2 > sub2/sub2 | |
5 | $ hg add -R sub2 |
|
5 | $ hg add -R sub2 | |
6 | adding sub2/sub2 |
|
6 | adding sub2/sub2 | |
7 | $ hg commit -R sub2 -m "sub2 import" |
|
7 | $ hg commit -R sub2 -m "sub2 import" | |
8 |
|
8 | |||
9 | Preparing the 'sub1' repo which depends on the subrepo 'sub2' |
|
9 | Preparing the 'sub1' repo which depends on the subrepo 'sub2' | |
10 |
|
10 | |||
11 | $ hg init sub1 |
|
11 | $ hg init sub1 | |
12 | $ echo sub1 > sub1/sub1 |
|
12 | $ echo sub1 > sub1/sub1 | |
13 | $ echo "sub2 = ../sub2" > sub1/.hgsub |
|
13 | $ echo "sub2 = ../sub2" > sub1/.hgsub | |
14 |
$ hg clone sub2 sub1/sub2 |
|
14 | $ hg clone sub2 sub1/sub2 | |
15 | updating to branch default |
|
15 | updating to branch default | |
16 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
16 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
17 | $ hg add -R sub1 |
|
17 | $ hg add -R sub1 | |
18 | adding sub1/.hgsub |
|
18 | adding sub1/.hgsub | |
19 | adding sub1/sub1 |
|
19 | adding sub1/sub1 | |
20 | $ hg commit -R sub1 -m "sub1 import" |
|
20 | $ hg commit -R sub1 -m "sub1 import" | |
21 | committing subrepository sub2 |
|
21 | committing subrepository sub2 | |
22 |
|
22 | |||
23 | Preparing the 'main' repo which depends on the subrepo 'sub1' |
|
23 | Preparing the 'main' repo which depends on the subrepo 'sub1' | |
24 |
|
24 | |||
25 | $ hg init main |
|
25 | $ hg init main | |
26 | $ echo main > main/main |
|
26 | $ echo main > main/main | |
27 | $ echo "sub1 = ../sub1" > main/.hgsub |
|
27 | $ echo "sub1 = ../sub1" > main/.hgsub | |
28 |
$ hg clone sub1 main/sub1 |
|
28 | $ hg clone sub1 main/sub1 | |
29 | updating to branch default |
|
29 | updating to branch default | |
30 | pulling ...sub2 |
|
30 | pulling subrepo sub2 from .*/sub2 | |
31 | requesting all changes |
|
31 | requesting all changes | |
32 | adding changesets |
|
32 | adding changesets | |
33 | adding manifests |
|
33 | adding manifests | |
34 | adding file changes |
|
34 | adding file changes | |
35 | added 1 changesets with 1 changes to 1 files |
|
35 | added 1 changesets with 1 changes to 1 files | |
36 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
36 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
37 | $ hg add -R main |
|
37 | $ hg add -R main | |
38 | adding main/.hgsub |
|
38 | adding main/.hgsub | |
39 | adding main/main |
|
39 | adding main/main | |
40 | $ hg commit -R main -m "main import" |
|
40 | $ hg commit -R main -m "main import" | |
41 | committing subrepository sub1 |
|
41 | committing subrepository sub1 | |
42 |
|
42 | |||
43 | Cleaning both repositories, just as a clone -U |
|
43 | Cleaning both repositories, just as a clone -U | |
44 |
|
44 | |||
45 | $ hg up -C -R sub2 null |
|
45 | $ hg up -C -R sub2 null | |
46 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
46 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
47 | $ hg up -C -R sub1 null |
|
47 | $ hg up -C -R sub1 null | |
48 | 0 files updated, 0 files merged, 3 files removed, 0 files unresolved |
|
48 | 0 files updated, 0 files merged, 3 files removed, 0 files unresolved | |
49 | $ hg up -C -R main null |
|
49 | $ hg up -C -R main null | |
50 | 0 files updated, 0 files merged, 3 files removed, 0 files unresolved |
|
50 | 0 files updated, 0 files merged, 3 files removed, 0 files unresolved | |
51 | $ rm -rf main/sub1 |
|
51 | $ rm -rf main/sub1 | |
52 | $ rm -rf sub1/sub2 |
|
52 | $ rm -rf sub1/sub2 | |
53 |
|
53 | |||
54 | Clone main |
|
54 | Clone main | |
55 |
|
55 | |||
56 |
$ hg clone main cloned |
|
56 | $ hg clone main cloned | |
57 | updating to branch default |
|
57 | updating to branch default | |
58 | pulling ...sub1 |
|
58 | pulling subrepo sub1 from .*/sub1 | |
59 | requesting all changes |
|
59 | requesting all changes | |
60 | adding changesets |
|
60 | adding changesets | |
61 | adding manifests |
|
61 | adding manifests | |
62 | adding file changes |
|
62 | adding file changes | |
63 | added 1 changesets with 3 changes to 3 files |
|
63 | added 1 changesets with 3 changes to 3 files | |
64 | pulling ...sub2 |
|
64 | pulling subrepo sub1/sub2 from .*/sub2 | |
65 | requesting all changes |
|
65 | requesting all changes | |
66 | adding changesets |
|
66 | adding changesets | |
67 | adding manifests |
|
67 | adding manifests | |
68 | adding file changes |
|
68 | adding file changes | |
69 | added 1 changesets with 1 changes to 1 files |
|
69 | added 1 changesets with 1 changes to 1 files | |
70 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
70 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
71 |
|
71 | |||
72 | Checking cloned repo ids |
|
72 | Checking cloned repo ids | |
73 |
|
73 | |||
74 | $ printf "cloned " ; hg id -R cloned |
|
74 | $ printf "cloned " ; hg id -R cloned | |
75 | cloned 7f491f53a367 tip |
|
75 | cloned 7f491f53a367 tip | |
76 | $ printf "cloned/sub1 " ; hg id -R cloned/sub1 |
|
76 | $ printf "cloned/sub1 " ; hg id -R cloned/sub1 | |
77 | cloned/sub1 fc3b4ce2696f tip |
|
77 | cloned/sub1 fc3b4ce2696f tip | |
78 | $ printf "cloned/sub1/sub2 " ; hg id -R cloned/sub1/sub2 |
|
78 | $ printf "cloned/sub1/sub2 " ; hg id -R cloned/sub1/sub2 | |
79 | cloned/sub1/sub2 c57a0840e3ba tip |
|
79 | cloned/sub1/sub2 c57a0840e3ba tip | |
80 |
|
80 | |||
81 | debugsub output for main and sub1 |
|
81 | debugsub output for main and sub1 | |
82 |
|
82 | |||
83 | $ hg debugsub -R cloned |
|
83 | $ hg debugsub -R cloned | |
84 | path sub1 |
|
84 | path sub1 | |
85 | source ../sub1 |
|
85 | source ../sub1 | |
86 | revision fc3b4ce2696f7741438c79207583768f2ce6b0dd |
|
86 | revision fc3b4ce2696f7741438c79207583768f2ce6b0dd | |
87 | $ hg debugsub -R cloned/sub1 |
|
87 | $ hg debugsub -R cloned/sub1 | |
88 | path sub2 |
|
88 | path sub2 | |
89 | source ../sub2 |
|
89 | source ../sub2 | |
90 | revision c57a0840e3badd667ef3c3ef65471609acb2ba3c |
|
90 | revision c57a0840e3badd667ef3c3ef65471609acb2ba3c | |
91 |
|
91 | |||
92 | Modifying deeply nested 'sub2' |
|
92 | Modifying deeply nested 'sub2' | |
93 |
|
93 | |||
94 | $ echo modified > cloned/sub1/sub2/sub2 |
|
94 | $ echo modified > cloned/sub1/sub2/sub2 | |
95 | $ hg commit -m "deep nested modif should trigger a commit" -R cloned |
|
95 | $ hg commit -m "deep nested modif should trigger a commit" -R cloned | |
96 | committing subrepository sub1 |
|
96 | committing subrepository sub1 | |
97 | committing subrepository sub1/sub2 |
|
97 | committing subrepository sub1/sub2 | |
98 |
|
98 | |||
99 | Checking modified node ids |
|
99 | Checking modified node ids | |
100 |
|
100 | |||
101 | $ printf "cloned " ; hg id -R cloned |
|
101 | $ printf "cloned " ; hg id -R cloned | |
102 | cloned ffe6649062fe tip |
|
102 | cloned ffe6649062fe tip | |
103 | $ printf "cloned/sub1 " ; hg id -R cloned/sub1 |
|
103 | $ printf "cloned/sub1 " ; hg id -R cloned/sub1 | |
104 | cloned/sub1 2ecb03bf44a9 tip |
|
104 | cloned/sub1 2ecb03bf44a9 tip | |
105 | $ printf "cloned/sub1/sub2 " ; hg id -R cloned/sub1/sub2 |
|
105 | $ printf "cloned/sub1/sub2 " ; hg id -R cloned/sub1/sub2 | |
106 | cloned/sub1/sub2 53dd3430bcaf tip |
|
106 | cloned/sub1/sub2 53dd3430bcaf tip | |
107 |
|
107 | |||
108 | debugsub output for main and sub1 |
|
108 | debugsub output for main and sub1 | |
109 |
|
109 | |||
110 | $ hg debugsub -R cloned |
|
110 | $ hg debugsub -R cloned | |
111 | path sub1 |
|
111 | path sub1 | |
112 | source ../sub1 |
|
112 | source ../sub1 | |
113 | revision 2ecb03bf44a94e749e8669481dd9069526ce7cb9 |
|
113 | revision 2ecb03bf44a94e749e8669481dd9069526ce7cb9 | |
114 | $ hg debugsub -R cloned/sub1 |
|
114 | $ hg debugsub -R cloned/sub1 | |
115 | path sub2 |
|
115 | path sub2 | |
116 | source ../sub2 |
|
116 | source ../sub2 | |
117 | revision 53dd3430bcaf5ab4a7c48262bcad6d441f510487 |
|
117 | revision 53dd3430bcaf5ab4a7c48262bcad6d441f510487 | |
118 |
|
118 | |||
119 | $ exit 0 |
|
119 | $ exit 0 |
General Comments 0
You need to be logged in to leave comments.
Login now