Show More
@@ -1,1045 +1,1045 b'' | |||||
1 | Let commit recurse into subrepos by default to match pre-2.0 behavior: |
|
1 | Let commit recurse into subrepos by default to match pre-2.0 behavior: | |
2 |
|
2 | |||
3 | $ echo "[ui]" >> $HGRCPATH |
|
3 | $ echo "[ui]" >> $HGRCPATH | |
4 | $ echo "commitsubrepos = Yes" >> $HGRCPATH |
|
4 | $ echo "commitsubrepos = Yes" >> $HGRCPATH | |
5 |
|
5 | |||
6 | $ hg init t |
|
6 | $ hg init t | |
7 | $ cd t |
|
7 | $ cd t | |
8 |
|
8 | |||
9 | first revision, no sub |
|
9 | first revision, no sub | |
10 |
|
10 | |||
11 | $ echo a > a |
|
11 | $ echo a > a | |
12 | $ hg ci -Am0 |
|
12 | $ hg ci -Am0 | |
13 | adding a |
|
13 | adding a | |
14 |
|
14 | |||
15 | add first sub |
|
15 | add first sub | |
16 |
|
16 | |||
17 | $ echo s = s > .hgsub |
|
17 | $ echo s = s > .hgsub | |
18 | $ hg add .hgsub |
|
18 | $ hg add .hgsub | |
19 | $ hg init s |
|
19 | $ hg init s | |
20 | $ echo a > s/a |
|
20 | $ echo a > s/a | |
21 |
|
21 | |||
22 | Issue2232: committing a subrepo without .hgsub |
|
22 | Issue2232: committing a subrepo without .hgsub | |
23 |
|
23 | |||
24 | $ hg ci -mbad s |
|
24 | $ hg ci -mbad s | |
25 | abort: can't commit subrepos without .hgsub |
|
25 | abort: can't commit subrepos without .hgsub | |
26 | [255] |
|
26 | [255] | |
27 |
|
27 | |||
28 | $ hg -R s ci -Ams0 |
|
28 | $ hg -R s ci -Ams0 | |
29 | adding a |
|
29 | adding a | |
30 | $ hg sum |
|
30 | $ hg sum | |
31 | parent: 0:f7b1eb17ad24 tip |
|
31 | parent: 0:f7b1eb17ad24 tip | |
32 | 0 |
|
32 | 0 | |
33 | branch: default |
|
33 | branch: default | |
34 | commit: 1 added, 1 subrepos |
|
34 | commit: 1 added, 1 subrepos | |
35 | update: (current) |
|
35 | update: (current) | |
36 | $ hg ci -m1 |
|
36 | $ hg ci -m1 | |
37 |
|
37 | |||
38 | Revert subrepo and test subrepo fileset keyword: |
|
38 | Revert subrepo and test subrepo fileset keyword: | |
39 |
|
39 | |||
40 | $ echo b > s/a |
|
40 | $ echo b > s/a | |
41 | $ hg revert "set:subrepo('glob:s*')" |
|
41 | $ hg revert "set:subrepo('glob:s*')" | |
42 | reverting subrepo s |
|
42 | reverting subrepo s | |
43 | reverting s/a (glob) |
|
43 | reverting s/a (glob) | |
44 | $ rm s/a.orig |
|
44 | $ rm s/a.orig | |
45 |
|
45 | |||
46 | Revert subrepo with no backup. The "reverting s/a" line is gone since |
|
46 | Revert subrepo with no backup. The "reverting s/a" line is gone since | |
47 | we're really running 'hg update' in the subrepo: |
|
47 | we're really running 'hg update' in the subrepo: | |
48 |
|
48 | |||
49 | $ echo b > s/a |
|
49 | $ echo b > s/a | |
50 | $ hg revert --no-backup s |
|
50 | $ hg revert --no-backup s | |
51 | reverting subrepo s |
|
51 | reverting subrepo s | |
52 |
|
52 | |||
53 | Issue2022: update -C |
|
53 | Issue2022: update -C | |
54 |
|
54 | |||
55 | $ echo b > s/a |
|
55 | $ echo b > s/a | |
56 | $ hg sum |
|
56 | $ hg sum | |
57 | parent: 1:7cf8cfea66e4 tip |
|
57 | parent: 1:7cf8cfea66e4 tip | |
58 | 1 |
|
58 | 1 | |
59 | branch: default |
|
59 | branch: default | |
60 | commit: 1 subrepos |
|
60 | commit: 1 subrepos | |
61 | update: (current) |
|
61 | update: (current) | |
62 | $ hg co -C 1 |
|
62 | $ hg co -C 1 | |
63 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
63 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
64 | $ hg sum |
|
64 | $ hg sum | |
65 | parent: 1:7cf8cfea66e4 tip |
|
65 | parent: 1:7cf8cfea66e4 tip | |
66 | 1 |
|
66 | 1 | |
67 | branch: default |
|
67 | branch: default | |
68 | commit: (clean) |
|
68 | commit: (clean) | |
69 | update: (current) |
|
69 | update: (current) | |
70 |
|
70 | |||
71 | commands that require a clean repo should respect subrepos |
|
71 | commands that require a clean repo should respect subrepos | |
72 |
|
72 | |||
73 | $ echo b >> s/a |
|
73 | $ echo b >> s/a | |
74 | $ hg backout tip |
|
74 | $ hg backout tip | |
75 | abort: uncommitted changes in subrepo s |
|
75 | abort: uncommitted changes in subrepo s | |
76 | [255] |
|
76 | [255] | |
77 | $ hg revert -C -R s s/a |
|
77 | $ hg revert -C -R s s/a | |
78 |
|
78 | |||
79 | add sub sub |
|
79 | add sub sub | |
80 |
|
80 | |||
81 | $ echo ss = ss > s/.hgsub |
|
81 | $ echo ss = ss > s/.hgsub | |
82 | $ hg init s/ss |
|
82 | $ hg init s/ss | |
83 | $ echo a > s/ss/a |
|
83 | $ echo a > s/ss/a | |
84 | $ hg -R s add s/.hgsub |
|
84 | $ hg -R s add s/.hgsub | |
85 | $ hg -R s/ss add s/ss/a |
|
85 | $ hg -R s/ss add s/ss/a | |
86 | $ hg sum |
|
86 | $ hg sum | |
87 | parent: 1:7cf8cfea66e4 tip |
|
87 | parent: 1:7cf8cfea66e4 tip | |
88 | 1 |
|
88 | 1 | |
89 | branch: default |
|
89 | branch: default | |
90 | commit: 1 subrepos |
|
90 | commit: 1 subrepos | |
91 | update: (current) |
|
91 | update: (current) | |
92 | $ hg ci -m2 |
|
92 | $ hg ci -m2 | |
93 | committing subrepository s |
|
93 | committing subrepository s | |
94 | committing subrepository s/ss (glob) |
|
94 | committing subrepository s/ss (glob) | |
95 | $ hg sum |
|
95 | $ hg sum | |
96 | parent: 2:df30734270ae tip |
|
96 | parent: 2:df30734270ae tip | |
97 | 2 |
|
97 | 2 | |
98 | branch: default |
|
98 | branch: default | |
99 | commit: (clean) |
|
99 | commit: (clean) | |
100 | update: (current) |
|
100 | update: (current) | |
101 |
|
101 | |||
102 | bump sub rev (and check it is ignored by ui.commitsubrepos) |
|
102 | bump sub rev (and check it is ignored by ui.commitsubrepos) | |
103 |
|
103 | |||
104 | $ echo b > s/a |
|
104 | $ echo b > s/a | |
105 | $ hg -R s ci -ms1 |
|
105 | $ hg -R s ci -ms1 | |
106 | $ hg --config ui.commitsubrepos=no ci -m3 |
|
106 | $ hg --config ui.commitsubrepos=no ci -m3 | |
107 |
|
107 | |||
108 | leave sub dirty (and check ui.commitsubrepos=no aborts the commit) |
|
108 | leave sub dirty (and check ui.commitsubrepos=no aborts the commit) | |
109 |
|
109 | |||
110 | $ echo c > s/a |
|
110 | $ echo c > s/a | |
111 | $ hg --config ui.commitsubrepos=no ci -m4 |
|
111 | $ hg --config ui.commitsubrepos=no ci -m4 | |
112 | abort: uncommitted changes in subrepo s |
|
112 | abort: uncommitted changes in subrepo s | |
113 | (use --subrepos for recursive commit) |
|
113 | (use --subrepos for recursive commit) | |
114 | [255] |
|
114 | [255] | |
115 | $ hg id |
|
115 | $ hg id | |
116 | f6affe3fbfaa+ tip |
|
116 | f6affe3fbfaa+ tip | |
117 | $ hg -R s ci -mc |
|
117 | $ hg -R s ci -mc | |
118 | $ hg id |
|
118 | $ hg id | |
119 | f6affe3fbfaa+ tip |
|
119 | f6affe3fbfaa+ tip | |
120 | $ echo d > s/a |
|
120 | $ echo d > s/a | |
121 | $ hg ci -m4 |
|
121 | $ hg ci -m4 | |
122 | committing subrepository s |
|
122 | committing subrepository s | |
123 | $ hg tip -R s |
|
123 | $ hg tip -R s | |
124 | changeset: 4:02dcf1d70411 |
|
124 | changeset: 4:02dcf1d70411 | |
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: 4 |
|
128 | summary: 4 | |
129 |
|
129 | |||
130 |
|
130 | |||
131 | check caching |
|
131 | check caching | |
132 |
|
132 | |||
133 | $ hg co 0 |
|
133 | $ hg co 0 | |
134 | 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
|
134 | 0 files updated, 0 files merged, 2 files removed, 0 files unresolved | |
135 | $ hg debugsub |
|
135 | $ hg debugsub | |
136 |
|
136 | |||
137 | restore |
|
137 | restore | |
138 |
|
138 | |||
139 | $ hg co |
|
139 | $ hg co | |
140 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
140 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
141 | $ hg debugsub |
|
141 | $ hg debugsub | |
142 | path s |
|
142 | path s | |
143 | source s |
|
143 | source s | |
144 | revision 02dcf1d704118aee3ee306ccfa1910850d5b05ef |
|
144 | revision 02dcf1d704118aee3ee306ccfa1910850d5b05ef | |
145 |
|
145 | |||
146 | new branch for merge tests |
|
146 | new branch for merge tests | |
147 |
|
147 | |||
148 | $ hg co 1 |
|
148 | $ hg co 1 | |
149 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
149 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
150 | $ echo t = t >> .hgsub |
|
150 | $ echo t = t >> .hgsub | |
151 | $ hg init t |
|
151 | $ hg init t | |
152 | $ echo t > t/t |
|
152 | $ echo t > t/t | |
153 | $ hg -R t add t |
|
153 | $ hg -R t add t | |
154 | adding t/t (glob) |
|
154 | adding t/t (glob) | |
155 |
|
155 | |||
156 | 5 |
|
156 | 5 | |
157 |
|
157 | |||
158 | $ hg ci -m5 # add sub |
|
158 | $ hg ci -m5 # add sub | |
159 | committing subrepository t |
|
159 | committing subrepository t | |
160 | created new head |
|
160 | created new head | |
161 | $ echo t2 > t/t |
|
161 | $ echo t2 > t/t | |
162 |
|
162 | |||
163 | 6 |
|
163 | 6 | |
164 |
|
164 | |||
165 | $ hg st -R s |
|
165 | $ hg st -R s | |
166 | $ hg ci -m6 # change sub |
|
166 | $ hg ci -m6 # change sub | |
167 | committing subrepository t |
|
167 | committing subrepository t | |
168 | $ hg debugsub |
|
168 | $ hg debugsub | |
169 | path s |
|
169 | path s | |
170 | source s |
|
170 | source s | |
171 | revision e4ece1bf43360ddc8f6a96432201a37b7cd27ae4 |
|
171 | revision e4ece1bf43360ddc8f6a96432201a37b7cd27ae4 | |
172 | path t |
|
172 | path t | |
173 | source t |
|
173 | source t | |
174 | revision 6747d179aa9a688023c4b0cad32e4c92bb7f34ad |
|
174 | revision 6747d179aa9a688023c4b0cad32e4c92bb7f34ad | |
175 | $ echo t3 > t/t |
|
175 | $ echo t3 > t/t | |
176 |
|
176 | |||
177 | 7 |
|
177 | 7 | |
178 |
|
178 | |||
179 | $ hg ci -m7 # change sub again for conflict test |
|
179 | $ hg ci -m7 # change sub again for conflict test | |
180 | committing subrepository t |
|
180 | committing subrepository t | |
181 | $ hg rm .hgsub |
|
181 | $ hg rm .hgsub | |
182 |
|
182 | |||
183 | 8 |
|
183 | 8 | |
184 |
|
184 | |||
185 | $ hg ci -m8 # remove sub |
|
185 | $ hg ci -m8 # remove sub | |
186 |
|
186 | |||
187 | merge tests |
|
187 | merge tests | |
188 |
|
188 | |||
189 | $ hg co -C 3 |
|
189 | $ hg co -C 3 | |
190 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
190 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
191 | $ hg merge 5 # test adding |
|
191 | $ hg merge 5 # test adding | |
192 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
192 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
193 | (branch merge, don't forget to commit) |
|
193 | (branch merge, don't forget to commit) | |
194 | $ hg debugsub |
|
194 | $ hg debugsub | |
195 | path s |
|
195 | path s | |
196 | source s |
|
196 | source s | |
197 | revision fc627a69481fcbe5f1135069e8a3881c023e4cf5 |
|
197 | revision fc627a69481fcbe5f1135069e8a3881c023e4cf5 | |
198 | path t |
|
198 | path t | |
199 | source t |
|
199 | source t | |
200 | revision 60ca1237c19474e7a3978b0dc1ca4e6f36d51382 |
|
200 | revision 60ca1237c19474e7a3978b0dc1ca4e6f36d51382 | |
201 | $ hg ci -m9 |
|
201 | $ hg ci -m9 | |
202 | created new head |
|
202 | created new head | |
203 | $ hg merge 6 --debug # test change |
|
203 | $ hg merge 6 --debug # test change | |
204 | searching for copies back to rev 2 |
|
204 | searching for copies back to rev 2 | |
205 | resolving manifests |
|
205 | resolving manifests | |
206 | overwrite: False, partial: False |
|
206 | overwrite: False, partial: False | |
207 | ancestor: 1f14a2e2d3ec, local: f0d2028bf86d+, remote: 1831e14459c4 |
|
207 | ancestor: 1f14a2e2d3ec, local: f0d2028bf86d+, remote: 1831e14459c4 | |
208 | .hgsubstate: versions differ -> m |
|
208 | .hgsubstate: versions differ -> m | |
209 | updating: .hgsubstate 1/1 files (100.00%) |
|
209 | updating: .hgsubstate 1/1 files (100.00%) | |
210 | subrepo merge f0d2028bf86d+ 1831e14459c4 1f14a2e2d3ec |
|
210 | subrepo merge f0d2028bf86d+ 1831e14459c4 1f14a2e2d3ec | |
211 | subrepo t: other changed, get t:6747d179aa9a688023c4b0cad32e4c92bb7f34ad:hg |
|
211 | subrepo t: other changed, get t:6747d179aa9a688023c4b0cad32e4c92bb7f34ad:hg | |
212 | getting subrepo t |
|
212 | getting subrepo t | |
213 | searching for copies back to rev 1 |
|
213 | searching for copies back to rev 1 | |
214 | resolving manifests |
|
214 | resolving manifests | |
215 | overwrite: False, partial: False |
|
215 | overwrite: False, partial: False | |
216 | ancestor: 60ca1237c194, local: 60ca1237c194+, remote: 6747d179aa9a |
|
216 | ancestor: 60ca1237c194, local: 60ca1237c194+, remote: 6747d179aa9a | |
217 | t: remote is newer -> g |
|
217 | t: remote is newer -> g | |
218 | updating: t 1/1 files (100.00%) |
|
218 | updating: t 1/1 files (100.00%) | |
219 | getting t |
|
219 | getting t | |
220 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
220 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
221 | (branch merge, don't forget to commit) |
|
221 | (branch merge, don't forget to commit) | |
222 | $ hg debugsub |
|
222 | $ hg debugsub | |
223 | path s |
|
223 | path s | |
224 | source s |
|
224 | source s | |
225 | revision fc627a69481fcbe5f1135069e8a3881c023e4cf5 |
|
225 | revision fc627a69481fcbe5f1135069e8a3881c023e4cf5 | |
226 | path t |
|
226 | path t | |
227 | source t |
|
227 | source t | |
228 | revision 6747d179aa9a688023c4b0cad32e4c92bb7f34ad |
|
228 | revision 6747d179aa9a688023c4b0cad32e4c92bb7f34ad | |
229 | $ echo conflict > t/t |
|
229 | $ echo conflict > t/t | |
230 | $ hg ci -m10 |
|
230 | $ hg ci -m10 | |
231 | committing subrepository t |
|
231 | committing subrepository t | |
232 | $ HGMERGE=internal:merge hg merge --debug 7 # test conflict |
|
232 | $ HGMERGE=internal:merge hg merge --debug 7 # test conflict | |
233 | searching for copies back to rev 2 |
|
233 | searching for copies back to rev 2 | |
234 | resolving manifests |
|
234 | resolving manifests | |
235 | overwrite: False, partial: False |
|
235 | overwrite: False, partial: False | |
236 | ancestor: 1831e14459c4, local: e45c8b14af55+, remote: f94576341bcf |
|
236 | ancestor: 1831e14459c4, local: e45c8b14af55+, remote: f94576341bcf | |
237 | .hgsubstate: versions differ -> m |
|
237 | .hgsubstate: versions differ -> m | |
238 | updating: .hgsubstate 1/1 files (100.00%) |
|
238 | updating: .hgsubstate 1/1 files (100.00%) | |
239 | subrepo merge e45c8b14af55+ f94576341bcf 1831e14459c4 |
|
239 | subrepo merge e45c8b14af55+ f94576341bcf 1831e14459c4 | |
240 | subrepo t: both sides changed, merge with t:7af322bc1198a32402fe903e0b7ebcfc5c9bf8f4:hg |
|
240 | subrepo t: both sides changed, merge with t:7af322bc1198a32402fe903e0b7ebcfc5c9bf8f4:hg | |
241 | merging subrepo t |
|
241 | merging subrepo t | |
242 | searching for copies back to rev 2 |
|
242 | searching for copies back to rev 2 | |
243 | resolving manifests |
|
243 | resolving manifests | |
244 | overwrite: False, partial: False |
|
244 | overwrite: False, partial: False | |
245 | ancestor: 6747d179aa9a, local: 20a0db6fbf6c+, remote: 7af322bc1198 |
|
245 | ancestor: 6747d179aa9a, local: 20a0db6fbf6c+, remote: 7af322bc1198 | |
246 | t: versions differ -> m |
|
246 | t: versions differ -> m | |
247 | preserving t for resolve of t |
|
247 | preserving t for resolve of t | |
248 | updating: t 1/1 files (100.00%) |
|
248 | updating: t 1/1 files (100.00%) | |
249 | picked tool 'internal:merge' for t (binary False symlink False) |
|
249 | picked tool 'internal:merge' for t (binary False symlink False) | |
250 | merging t |
|
250 | merging t | |
251 | my t@20a0db6fbf6c+ other t@7af322bc1198 ancestor t@6747d179aa9a |
|
251 | my t@20a0db6fbf6c+ other t@7af322bc1198 ancestor t@6747d179aa9a | |
252 | warning: conflicts during merge. |
|
252 | warning: conflicts during merge. | |
253 | merging t incomplete! (edit conflicts, then use 'hg resolve --mark') |
|
253 | merging t incomplete! (edit conflicts, then use 'hg resolve --mark') | |
254 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
254 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
255 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
255 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon | |
256 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
256 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
257 | (branch merge, don't forget to commit) |
|
257 | (branch merge, don't forget to commit) | |
258 |
|
258 | |||
259 | should conflict |
|
259 | should conflict | |
260 |
|
260 | |||
261 | $ cat t/t |
|
261 | $ cat t/t | |
262 | <<<<<<< local |
|
262 | <<<<<<< local | |
263 | conflict |
|
263 | conflict | |
264 | ======= |
|
264 | ======= | |
265 | t3 |
|
265 | t3 | |
266 | >>>>>>> other |
|
266 | >>>>>>> other | |
267 |
|
267 | |||
268 | clone |
|
268 | clone | |
269 |
|
269 | |||
270 | $ cd .. |
|
270 | $ cd .. | |
271 | $ hg clone t tc |
|
271 | $ hg clone t tc | |
272 | updating to branch default |
|
272 | updating to branch default | |
273 | cloning subrepo s from $TESTTMP/t/s (glob) |
|
273 | cloning subrepo s from $TESTTMP/t/s (glob) | |
274 | cloning subrepo s/ss from $TESTTMP/t/s/ss (glob) |
|
274 | cloning subrepo s/ss from $TESTTMP/t/s/ss (glob) | |
275 | cloning subrepo t from $TESTTMP/t/t (glob) |
|
275 | cloning subrepo t from $TESTTMP/t/t (glob) | |
276 | 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 | |
277 | $ cd tc |
|
277 | $ cd tc | |
278 | $ hg debugsub |
|
278 | $ hg debugsub | |
279 | path s |
|
279 | path s | |
280 | source s |
|
280 | source s | |
281 | revision fc627a69481fcbe5f1135069e8a3881c023e4cf5 |
|
281 | revision fc627a69481fcbe5f1135069e8a3881c023e4cf5 | |
282 | path t |
|
282 | path t | |
283 | source t |
|
283 | source t | |
284 | revision 20a0db6fbf6c3d2836e6519a642ae929bfc67c0e |
|
284 | revision 20a0db6fbf6c3d2836e6519a642ae929bfc67c0e | |
285 |
|
285 | |||
286 | push |
|
286 | push | |
287 |
|
287 | |||
288 | $ echo bah > t/t |
|
288 | $ echo bah > t/t | |
289 | $ hg ci -m11 |
|
289 | $ hg ci -m11 | |
290 | committing subrepository t |
|
290 | committing subrepository t | |
291 | $ hg push |
|
291 | $ hg push | |
292 | pushing to $TESTTMP/t (glob) |
|
292 | pushing to $TESTTMP/t (glob) | |
293 | pushing subrepo s/ss to $TESTTMP/t/s/ss (glob) |
|
293 | pushing subrepo s/ss to $TESTTMP/t/s/ss (glob) | |
294 | searching for changes |
|
294 | searching for changes | |
295 | no changes found |
|
295 | no changes found | |
296 | pushing subrepo s to $TESTTMP/t/s (glob) |
|
296 | pushing subrepo s to $TESTTMP/t/s (glob) | |
297 | searching for changes |
|
297 | searching for changes | |
298 | no changes found |
|
298 | no changes found | |
299 | pushing subrepo t to $TESTTMP/t/t (glob) |
|
299 | pushing subrepo t to $TESTTMP/t/t (glob) | |
300 | searching for changes |
|
300 | searching for changes | |
301 | adding changesets |
|
301 | adding changesets | |
302 | adding manifests |
|
302 | adding manifests | |
303 | adding file changes |
|
303 | adding file changes | |
304 | added 1 changesets with 1 changes to 1 files |
|
304 | added 1 changesets with 1 changes to 1 files | |
305 | searching for changes |
|
305 | searching for changes | |
306 | adding changesets |
|
306 | adding changesets | |
307 | adding manifests |
|
307 | adding manifests | |
308 | adding file changes |
|
308 | adding file changes | |
309 | added 1 changesets with 1 changes to 1 files |
|
309 | added 1 changesets with 1 changes to 1 files | |
310 |
|
310 | |||
311 | push -f |
|
311 | push -f | |
312 |
|
312 | |||
313 | $ echo bah > s/a |
|
313 | $ echo bah > s/a | |
314 | $ hg ci -m12 |
|
314 | $ hg ci -m12 | |
315 | committing subrepository s |
|
315 | committing subrepository s | |
316 | $ hg push |
|
316 | $ hg push | |
317 | pushing to $TESTTMP/t (glob) |
|
317 | pushing to $TESTTMP/t (glob) | |
318 | pushing subrepo s/ss to $TESTTMP/t/s/ss (glob) |
|
318 | pushing subrepo s/ss to $TESTTMP/t/s/ss (glob) | |
319 | searching for changes |
|
319 | searching for changes | |
320 | no changes found |
|
320 | no changes found | |
321 | pushing subrepo s to $TESTTMP/t/s (glob) |
|
321 | pushing subrepo s to $TESTTMP/t/s (glob) | |
322 | searching for changes |
|
322 | searching for changes | |
323 | abort: push creates new remote head 12a213df6fa9! |
|
323 | abort: push creates new remote head 12a213df6fa9! | |
324 | (did you forget to merge? use push -f to force) |
|
324 | (did you forget to merge? use push -f to force) | |
325 | [255] |
|
325 | [255] | |
326 | $ hg push -f |
|
326 | $ hg push -f | |
327 | pushing to $TESTTMP/t (glob) |
|
327 | pushing to $TESTTMP/t (glob) | |
328 | pushing subrepo s/ss to $TESTTMP/t/s/ss (glob) |
|
328 | pushing subrepo s/ss to $TESTTMP/t/s/ss (glob) | |
329 | searching for changes |
|
329 | searching for changes | |
330 | no changes found |
|
330 | no changes found | |
331 | pushing subrepo s to $TESTTMP/t/s (glob) |
|
331 | pushing subrepo s to $TESTTMP/t/s (glob) | |
332 | searching for changes |
|
332 | searching for changes | |
333 | adding changesets |
|
333 | adding changesets | |
334 | adding manifests |
|
334 | adding manifests | |
335 | adding file changes |
|
335 | adding file changes | |
336 | added 1 changesets with 1 changes to 1 files (+1 heads) |
|
336 | added 1 changesets with 1 changes to 1 files (+1 heads) | |
337 | pushing subrepo t to $TESTTMP/t/t (glob) |
|
337 | pushing subrepo t to $TESTTMP/t/t (glob) | |
338 | searching for changes |
|
338 | searching for changes | |
339 | no changes found |
|
339 | no changes found | |
340 | searching for changes |
|
340 | searching for changes | |
341 | adding changesets |
|
341 | adding changesets | |
342 | adding manifests |
|
342 | adding manifests | |
343 | adding file changes |
|
343 | adding file changes | |
344 | added 1 changesets with 1 changes to 1 files |
|
344 | added 1 changesets with 1 changes to 1 files | |
345 |
|
345 | |||
346 | update |
|
346 | update | |
347 |
|
347 | |||
348 | $ cd ../t |
|
348 | $ cd ../t | |
349 | $ hg up -C # discard our earlier merge |
|
349 | $ hg up -C # discard our earlier merge | |
350 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
350 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
351 | $ echo blah > t/t |
|
351 | $ echo blah > t/t | |
352 | $ hg ci -m13 |
|
352 | $ hg ci -m13 | |
353 | committing subrepository t |
|
353 | committing subrepository t | |
354 |
|
354 | |||
355 | pull |
|
355 | pull | |
356 |
|
356 | |||
357 | $ cd ../tc |
|
357 | $ cd ../tc | |
358 | $ hg pull |
|
358 | $ hg pull | |
359 | pulling from $TESTTMP/t (glob) |
|
359 | pulling from $TESTTMP/t (glob) | |
360 | searching for changes |
|
360 | searching for changes | |
361 | adding changesets |
|
361 | adding changesets | |
362 | adding manifests |
|
362 | adding manifests | |
363 | adding file changes |
|
363 | adding file changes | |
364 | added 1 changesets with 1 changes to 1 files |
|
364 | added 1 changesets with 1 changes to 1 files | |
365 | (run 'hg update' to get a working copy) |
|
365 | (run 'hg update' to get a working copy) | |
366 |
|
366 | |||
367 | should pull t |
|
367 | should pull t | |
368 |
|
368 | |||
369 | $ hg up |
|
369 | $ hg up | |
370 | pulling subrepo t from $TESTTMP/t/t (glob) |
|
370 | pulling subrepo t from $TESTTMP/t/t (glob) | |
371 | searching for changes |
|
371 | searching for changes | |
372 | adding changesets |
|
372 | adding changesets | |
373 | adding manifests |
|
373 | adding manifests | |
374 | adding file changes |
|
374 | adding file changes | |
375 | added 1 changesets with 1 changes to 1 files |
|
375 | added 1 changesets with 1 changes to 1 files | |
376 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
376 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
377 | $ cat t/t |
|
377 | $ cat t/t | |
378 | blah |
|
378 | blah | |
379 |
|
379 | |||
380 | bogus subrepo path aborts |
|
380 | bogus subrepo path aborts | |
381 |
|
381 | |||
382 | $ echo 'bogus=[boguspath' >> .hgsub |
|
382 | $ echo 'bogus=[boguspath' >> .hgsub | |
383 | $ hg ci -m 'bogus subrepo path' |
|
383 | $ hg ci -m 'bogus subrepo path' | |
384 | abort: missing ] in subrepo source |
|
384 | abort: missing ] in subrepo source | |
385 | [255] |
|
385 | [255] | |
386 |
|
386 | |||
387 | Issue1986: merge aborts when trying to merge a subrepo that |
|
387 | Issue1986: merge aborts when trying to merge a subrepo that | |
388 | shouldn't need merging |
|
388 | shouldn't need merging | |
389 |
|
389 | |||
390 | # subrepo layout |
|
390 | # subrepo layout | |
391 | # |
|
391 | # | |
392 | # o 5 br |
|
392 | # o 5 br | |
393 | # /| |
|
393 | # /| | |
394 | # o | 4 default |
|
394 | # o | 4 default | |
395 | # | | |
|
395 | # | | | |
396 | # | o 3 br |
|
396 | # | o 3 br | |
397 | # |/| |
|
397 | # |/| | |
398 | # o | 2 default |
|
398 | # o | 2 default | |
399 | # | | |
|
399 | # | | | |
400 | # | o 1 br |
|
400 | # | o 1 br | |
401 | # |/ |
|
401 | # |/ | |
402 | # o 0 default |
|
402 | # o 0 default | |
403 |
|
403 | |||
404 | $ cd .. |
|
404 | $ cd .. | |
405 | $ rm -rf sub |
|
405 | $ rm -rf sub | |
406 | $ hg init main |
|
406 | $ hg init main | |
407 | $ cd main |
|
407 | $ cd main | |
408 | $ hg init s |
|
408 | $ hg init s | |
409 | $ cd s |
|
409 | $ cd s | |
410 | $ echo a > a |
|
410 | $ echo a > a | |
411 | $ hg ci -Am1 |
|
411 | $ hg ci -Am1 | |
412 | adding a |
|
412 | adding a | |
413 | $ hg branch br |
|
413 | $ hg branch br | |
414 | marked working directory as branch br |
|
414 | marked working directory as branch br | |
415 | (branches are permanent and global, did you want a bookmark?) |
|
415 | (branches are permanent and global, did you want a bookmark?) | |
416 | $ echo a >> a |
|
416 | $ echo a >> a | |
417 | $ hg ci -m1 |
|
417 | $ hg ci -m1 | |
418 | $ hg up default |
|
418 | $ hg up default | |
419 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
419 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
420 | $ echo b > b |
|
420 | $ echo b > b | |
421 | $ hg ci -Am1 |
|
421 | $ hg ci -Am1 | |
422 | adding b |
|
422 | adding b | |
423 | $ hg up br |
|
423 | $ hg up br | |
424 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
424 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
425 | $ hg merge tip |
|
425 | $ hg merge tip | |
426 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
426 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
427 | (branch merge, don't forget to commit) |
|
427 | (branch merge, don't forget to commit) | |
428 | $ hg ci -m1 |
|
428 | $ hg ci -m1 | |
429 | $ hg up 2 |
|
429 | $ hg up 2 | |
430 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
430 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
431 | $ echo c > c |
|
431 | $ echo c > c | |
432 | $ hg ci -Am1 |
|
432 | $ hg ci -Am1 | |
433 | adding c |
|
433 | adding c | |
434 | $ hg up 3 |
|
434 | $ hg up 3 | |
435 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
435 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
436 | $ hg merge 4 |
|
436 | $ hg merge 4 | |
437 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
437 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
438 | (branch merge, don't forget to commit) |
|
438 | (branch merge, don't forget to commit) | |
439 | $ hg ci -m1 |
|
439 | $ hg ci -m1 | |
440 |
|
440 | |||
441 | # main repo layout: |
|
441 | # main repo layout: | |
442 | # |
|
442 | # | |
443 | # * <-- try to merge default into br again |
|
443 | # * <-- try to merge default into br again | |
444 | # .`| |
|
444 | # .`| | |
445 | # . o 5 br --> substate = 5 |
|
445 | # . o 5 br --> substate = 5 | |
446 | # . | |
|
446 | # . | | |
447 | # o | 4 default --> substate = 4 |
|
447 | # o | 4 default --> substate = 4 | |
448 | # | | |
|
448 | # | | | |
449 | # | o 3 br --> substate = 2 |
|
449 | # | o 3 br --> substate = 2 | |
450 | # |/| |
|
450 | # |/| | |
451 | # o | 2 default --> substate = 2 |
|
451 | # o | 2 default --> substate = 2 | |
452 | # | | |
|
452 | # | | | |
453 | # | o 1 br --> substate = 3 |
|
453 | # | o 1 br --> substate = 3 | |
454 | # |/ |
|
454 | # |/ | |
455 | # o 0 default --> substate = 2 |
|
455 | # o 0 default --> substate = 2 | |
456 |
|
456 | |||
457 | $ cd .. |
|
457 | $ cd .. | |
458 | $ echo 's = s' > .hgsub |
|
458 | $ echo 's = s' > .hgsub | |
459 | $ hg -R s up 2 |
|
459 | $ hg -R s up 2 | |
460 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
460 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
461 | $ hg ci -Am1 |
|
461 | $ hg ci -Am1 | |
462 | adding .hgsub |
|
462 | adding .hgsub | |
463 | $ hg branch br |
|
463 | $ hg branch br | |
464 | marked working directory as branch br |
|
464 | marked working directory as branch br | |
465 | (branches are permanent and global, did you want a bookmark?) |
|
465 | (branches are permanent and global, did you want a bookmark?) | |
466 | $ echo b > b |
|
466 | $ echo b > b | |
467 | $ hg -R s up 3 |
|
467 | $ hg -R s up 3 | |
468 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
468 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
469 | $ hg ci -Am1 |
|
469 | $ hg ci -Am1 | |
470 | adding b |
|
470 | adding b | |
471 | $ hg up default |
|
471 | $ hg up default | |
472 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
472 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
473 | $ echo c > c |
|
473 | $ echo c > c | |
474 | $ hg ci -Am1 |
|
474 | $ hg ci -Am1 | |
475 | adding c |
|
475 | adding c | |
476 | $ hg up 1 |
|
476 | $ hg up 1 | |
477 | 2 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
477 | 2 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
478 | $ hg merge 2 |
|
478 | $ hg merge 2 | |
479 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
479 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
480 | (branch merge, don't forget to commit) |
|
480 | (branch merge, don't forget to commit) | |
481 | $ hg ci -m1 |
|
481 | $ hg ci -m1 | |
482 | $ hg up 2 |
|
482 | $ hg up 2 | |
483 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
483 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
484 | $ hg -R s up 4 |
|
484 | $ hg -R s up 4 | |
485 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
485 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
486 | $ echo d > d |
|
486 | $ echo d > d | |
487 | $ hg ci -Am1 |
|
487 | $ hg ci -Am1 | |
488 | adding d |
|
488 | adding d | |
489 | $ hg up 3 |
|
489 | $ hg up 3 | |
490 | 2 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
490 | 2 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
491 | $ hg -R s up 5 |
|
491 | $ hg -R s up 5 | |
492 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
492 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
493 | $ echo e > e |
|
493 | $ echo e > e | |
494 | $ hg ci -Am1 |
|
494 | $ hg ci -Am1 | |
495 | adding e |
|
495 | adding e | |
496 |
|
496 | |||
497 | $ hg up 5 |
|
497 | $ hg up 5 | |
498 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
498 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
499 | $ hg merge 4 # try to merge default into br again |
|
499 | $ hg merge 4 # try to merge default into br again | |
500 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
500 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
501 | (branch merge, don't forget to commit) |
|
501 | (branch merge, don't forget to commit) | |
502 | $ cd .. |
|
502 | $ cd .. | |
503 |
|
503 | |||
504 | test subrepo delete from .hgsubstate |
|
504 | test subrepo delete from .hgsubstate | |
505 |
|
505 | |||
506 | $ hg init testdelete |
|
506 | $ hg init testdelete | |
507 | $ mkdir testdelete/nested testdelete/nested2 |
|
507 | $ mkdir testdelete/nested testdelete/nested2 | |
508 | $ hg init testdelete/nested |
|
508 | $ hg init testdelete/nested | |
509 | $ hg init testdelete/nested2 |
|
509 | $ hg init testdelete/nested2 | |
510 | $ echo test > testdelete/nested/foo |
|
510 | $ echo test > testdelete/nested/foo | |
511 | $ echo test > testdelete/nested2/foo |
|
511 | $ echo test > testdelete/nested2/foo | |
512 | $ hg -R testdelete/nested add |
|
512 | $ hg -R testdelete/nested add | |
513 | adding testdelete/nested/foo (glob) |
|
513 | adding testdelete/nested/foo (glob) | |
514 | $ hg -R testdelete/nested2 add |
|
514 | $ hg -R testdelete/nested2 add | |
515 | adding testdelete/nested2/foo (glob) |
|
515 | adding testdelete/nested2/foo (glob) | |
516 | $ hg -R testdelete/nested ci -m test |
|
516 | $ hg -R testdelete/nested ci -m test | |
517 | $ hg -R testdelete/nested2 ci -m test |
|
517 | $ hg -R testdelete/nested2 ci -m test | |
518 | $ echo nested = nested > testdelete/.hgsub |
|
518 | $ echo nested = nested > testdelete/.hgsub | |
519 | $ echo nested2 = nested2 >> testdelete/.hgsub |
|
519 | $ echo nested2 = nested2 >> testdelete/.hgsub | |
520 | $ hg -R testdelete add |
|
520 | $ hg -R testdelete add | |
521 | adding testdelete/.hgsub (glob) |
|
521 | adding testdelete/.hgsub (glob) | |
522 | $ hg -R testdelete ci -m "nested 1 & 2 added" |
|
522 | $ hg -R testdelete ci -m "nested 1 & 2 added" | |
523 | $ echo nested = nested > testdelete/.hgsub |
|
523 | $ echo nested = nested > testdelete/.hgsub | |
524 | $ hg -R testdelete ci -m "nested 2 deleted" |
|
524 | $ hg -R testdelete ci -m "nested 2 deleted" | |
525 | $ cat testdelete/.hgsubstate |
|
525 | $ cat testdelete/.hgsubstate | |
526 | bdf5c9a3103743d900b12ae0db3ffdcfd7b0d878 nested |
|
526 | bdf5c9a3103743d900b12ae0db3ffdcfd7b0d878 nested | |
527 | $ hg -R testdelete remove testdelete/.hgsub |
|
527 | $ hg -R testdelete remove testdelete/.hgsub | |
528 | $ hg -R testdelete ci -m ".hgsub deleted" |
|
528 | $ hg -R testdelete ci -m ".hgsub deleted" | |
529 | $ cat testdelete/.hgsubstate |
|
529 | $ cat testdelete/.hgsubstate | |
530 | bdf5c9a3103743d900b12ae0db3ffdcfd7b0d878 nested |
|
530 | bdf5c9a3103743d900b12ae0db3ffdcfd7b0d878 nested | |
531 |
|
531 | |||
532 | test repository cloning |
|
532 | test repository cloning | |
533 |
|
533 | |||
534 | $ mkdir mercurial mercurial2 |
|
534 | $ mkdir mercurial mercurial2 | |
535 | $ hg init nested_absolute |
|
535 | $ hg init nested_absolute | |
536 | $ echo test > nested_absolute/foo |
|
536 | $ echo test > nested_absolute/foo | |
537 | $ hg -R nested_absolute add |
|
537 | $ hg -R nested_absolute add | |
538 | adding nested_absolute/foo (glob) |
|
538 | adding nested_absolute/foo (glob) | |
539 | $ hg -R nested_absolute ci -mtest |
|
539 | $ hg -R nested_absolute ci -mtest | |
540 | $ cd mercurial |
|
540 | $ cd mercurial | |
541 | $ hg init nested_relative |
|
541 | $ hg init nested_relative | |
542 | $ echo test2 > nested_relative/foo2 |
|
542 | $ echo test2 > nested_relative/foo2 | |
543 | $ hg -R nested_relative add |
|
543 | $ hg -R nested_relative add | |
544 | adding nested_relative/foo2 (glob) |
|
544 | adding nested_relative/foo2 (glob) | |
545 | $ hg -R nested_relative ci -mtest2 |
|
545 | $ hg -R nested_relative ci -mtest2 | |
546 | $ hg init main |
|
546 | $ hg init main | |
547 | $ echo "nested_relative = ../nested_relative" > main/.hgsub |
|
547 | $ echo "nested_relative = ../nested_relative" > main/.hgsub | |
548 | $ echo "nested_absolute = `pwd`/nested_absolute" >> main/.hgsub |
|
548 | $ echo "nested_absolute = `pwd`/nested_absolute" >> main/.hgsub | |
549 | $ hg -R main add |
|
549 | $ hg -R main add | |
550 | adding main/.hgsub (glob) |
|
550 | adding main/.hgsub (glob) | |
551 | $ hg -R main ci -m "add subrepos" |
|
551 | $ hg -R main ci -m "add subrepos" | |
552 | $ cd .. |
|
552 | $ cd .. | |
553 | $ hg clone mercurial/main mercurial2/main |
|
553 | $ hg clone mercurial/main mercurial2/main | |
554 | updating to branch default |
|
554 | updating to branch default | |
555 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
555 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
556 | $ cat mercurial2/main/nested_absolute/.hg/hgrc \ |
|
556 | $ cat mercurial2/main/nested_absolute/.hg/hgrc \ | |
557 | > mercurial2/main/nested_relative/.hg/hgrc |
|
557 | > mercurial2/main/nested_relative/.hg/hgrc | |
558 | [paths] |
|
558 | [paths] | |
559 | default = $TESTTMP/mercurial/nested_absolute |
|
559 | default = $TESTTMP/mercurial/nested_absolute | |
560 | [paths] |
|
560 | [paths] | |
561 | default = $TESTTMP/mercurial/nested_relative |
|
561 | default = $TESTTMP/mercurial/nested_relative | |
562 | $ rm -rf mercurial mercurial2 |
|
562 | $ rm -rf mercurial mercurial2 | |
563 |
|
563 | |||
564 | Issue1977: multirepo push should fail if subrepo push fails |
|
564 | Issue1977: multirepo push should fail if subrepo push fails | |
565 |
|
565 | |||
566 | $ hg init repo |
|
566 | $ hg init repo | |
567 | $ hg init repo/s |
|
567 | $ hg init repo/s | |
568 | $ echo a > repo/s/a |
|
568 | $ echo a > repo/s/a | |
569 | $ hg -R repo/s ci -Am0 |
|
569 | $ hg -R repo/s ci -Am0 | |
570 | adding a |
|
570 | adding a | |
571 | $ echo s = s > repo/.hgsub |
|
571 | $ echo s = s > repo/.hgsub | |
572 | $ hg -R repo ci -Am1 |
|
572 | $ hg -R repo ci -Am1 | |
573 | adding .hgsub |
|
573 | adding .hgsub | |
574 | $ hg clone repo repo2 |
|
574 | $ hg clone repo repo2 | |
575 | updating to branch default |
|
575 | updating to branch default | |
576 | cloning subrepo s from $TESTTMP/repo/s (glob) |
|
576 | cloning subrepo s from $TESTTMP/repo/s (glob) | |
577 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
577 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
578 | $ hg -q -R repo2 pull -u |
|
578 | $ hg -q -R repo2 pull -u | |
579 | $ echo 1 > repo2/s/a |
|
579 | $ echo 1 > repo2/s/a | |
580 | $ hg -R repo2/s ci -m2 |
|
580 | $ hg -R repo2/s ci -m2 | |
581 | $ hg -q -R repo2/s push |
|
581 | $ hg -q -R repo2/s push | |
582 | $ hg -R repo2/s up -C 0 |
|
582 | $ hg -R repo2/s up -C 0 | |
583 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
583 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
584 | $ echo 2 > repo2/s/b |
|
584 | $ echo 2 > repo2/s/b | |
585 | $ hg -R repo2/s ci -m3 -A |
|
585 | $ hg -R repo2/s ci -m3 -A | |
586 | adding b |
|
586 | adding b | |
587 | created new head |
|
587 | created new head | |
588 | $ hg -R repo2 ci -m3 |
|
588 | $ hg -R repo2 ci -m3 | |
589 | $ hg -q -R repo2 push |
|
589 | $ hg -q -R repo2 push | |
590 | abort: push creates new remote head cc505f09a8b2! |
|
590 | abort: push creates new remote head cc505f09a8b2! | |
591 | (did you forget to merge? use push -f to force) |
|
591 | (did you forget to merge? use push -f to force) | |
592 | [255] |
|
592 | [255] | |
593 | $ hg -R repo update |
|
593 | $ hg -R repo update | |
594 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
594 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
595 |
|
595 | |||
596 | test if untracked file is not overwritten |
|
596 | test if untracked file is not overwritten | |
597 |
|
597 | |||
598 | $ echo issue3276_ok > repo/s/b |
|
598 | $ echo issue3276_ok > repo/s/b | |
599 | $ hg -R repo2 push -f -q |
|
599 | $ hg -R repo2 push -f -q | |
600 | $ hg -R repo update |
|
600 | $ hg -R repo update | |
601 | b: untracked file differs |
|
601 | b: untracked file differs | |
602 | abort: untracked files in working directory differ from files in requested revision |
|
602 | abort: untracked files in working directory differ from files in requested revision | |
603 | [255] |
|
603 | [255] | |
604 |
|
604 | |||
605 | $ cat repo/s/b |
|
605 | $ cat repo/s/b | |
606 | issue3276_ok |
|
606 | issue3276_ok | |
607 | $ rm repo/s/b |
|
607 | $ rm repo/s/b | |
608 | $ hg -R repo revert --all |
|
608 | $ hg -R repo revert --all | |
609 | reverting repo/.hgsubstate |
|
609 | reverting repo/.hgsubstate (glob) | |
610 | reverting subrepo s |
|
610 | reverting subrepo s | |
611 | $ hg -R repo update |
|
611 | $ hg -R repo update | |
612 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
612 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
613 | $ cat repo/s/b |
|
613 | $ cat repo/s/b | |
614 | 2 |
|
614 | 2 | |
615 | $ rm -rf repo2 repo |
|
615 | $ rm -rf repo2 repo | |
616 |
|
616 | |||
617 |
|
617 | |||
618 | Issue1852 subrepos with relative paths always push/pull relative to default |
|
618 | Issue1852 subrepos with relative paths always push/pull relative to default | |
619 |
|
619 | |||
620 | Prepare a repo with subrepo |
|
620 | Prepare a repo with subrepo | |
621 |
|
621 | |||
622 | $ hg init issue1852a |
|
622 | $ hg init issue1852a | |
623 | $ cd issue1852a |
|
623 | $ cd issue1852a | |
624 | $ hg init sub/repo |
|
624 | $ hg init sub/repo | |
625 | $ echo test > sub/repo/foo |
|
625 | $ echo test > sub/repo/foo | |
626 | $ hg -R sub/repo add sub/repo/foo |
|
626 | $ hg -R sub/repo add sub/repo/foo | |
627 | $ echo sub/repo = sub/repo > .hgsub |
|
627 | $ echo sub/repo = sub/repo > .hgsub | |
628 | $ hg add .hgsub |
|
628 | $ hg add .hgsub | |
629 | $ hg ci -mtest |
|
629 | $ hg ci -mtest | |
630 | committing subrepository sub/repo (glob) |
|
630 | committing subrepository sub/repo (glob) | |
631 | $ echo test >> sub/repo/foo |
|
631 | $ echo test >> sub/repo/foo | |
632 | $ hg ci -mtest |
|
632 | $ hg ci -mtest | |
633 | committing subrepository sub/repo (glob) |
|
633 | committing subrepository sub/repo (glob) | |
634 | $ cd .. |
|
634 | $ cd .. | |
635 |
|
635 | |||
636 | Create repo without default path, pull top repo, and see what happens on update |
|
636 | Create repo without default path, pull top repo, and see what happens on update | |
637 |
|
637 | |||
638 | $ hg init issue1852b |
|
638 | $ hg init issue1852b | |
639 | $ hg -R issue1852b pull issue1852a |
|
639 | $ hg -R issue1852b pull issue1852a | |
640 | pulling from issue1852a |
|
640 | pulling from issue1852a | |
641 | requesting all changes |
|
641 | requesting all changes | |
642 | adding changesets |
|
642 | adding changesets | |
643 | adding manifests |
|
643 | adding manifests | |
644 | adding file changes |
|
644 | adding file changes | |
645 | added 2 changesets with 3 changes to 2 files |
|
645 | added 2 changesets with 3 changes to 2 files | |
646 | (run 'hg update' to get a working copy) |
|
646 | (run 'hg update' to get a working copy) | |
647 | $ hg -R issue1852b update |
|
647 | $ hg -R issue1852b update | |
648 | abort: default path for subrepository sub/repo not found (glob) |
|
648 | abort: default path for subrepository sub/repo not found (glob) | |
649 | [255] |
|
649 | [255] | |
650 |
|
650 | |||
651 | Pull -u now doesn't help |
|
651 | Pull -u now doesn't help | |
652 |
|
652 | |||
653 | $ hg -R issue1852b pull -u issue1852a |
|
653 | $ hg -R issue1852b pull -u issue1852a | |
654 | pulling from issue1852a |
|
654 | pulling from issue1852a | |
655 | searching for changes |
|
655 | searching for changes | |
656 | no changes found |
|
656 | no changes found | |
657 |
|
657 | |||
658 | Try the same, but with pull -u |
|
658 | Try the same, but with pull -u | |
659 |
|
659 | |||
660 | $ hg init issue1852c |
|
660 | $ hg init issue1852c | |
661 | $ hg -R issue1852c pull -r0 -u issue1852a |
|
661 | $ hg -R issue1852c pull -r0 -u issue1852a | |
662 | pulling from issue1852a |
|
662 | pulling from issue1852a | |
663 | adding changesets |
|
663 | adding changesets | |
664 | adding manifests |
|
664 | adding manifests | |
665 | adding file changes |
|
665 | adding file changes | |
666 | added 1 changesets with 2 changes to 2 files |
|
666 | added 1 changesets with 2 changes to 2 files | |
667 | cloning subrepo sub/repo from issue1852a/sub/repo (glob) |
|
667 | cloning subrepo sub/repo from issue1852a/sub/repo (glob) | |
668 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
668 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
669 |
|
669 | |||
670 | Try to push from the other side |
|
670 | Try to push from the other side | |
671 |
|
671 | |||
672 | $ hg -R issue1852a push `pwd`/issue1852c |
|
672 | $ hg -R issue1852a push `pwd`/issue1852c | |
673 | pushing to $TESTTMP/issue1852c |
|
673 | pushing to $TESTTMP/issue1852c | |
674 | pushing subrepo sub/repo to $TESTTMP/issue1852c/sub/repo (glob) |
|
674 | pushing subrepo sub/repo to $TESTTMP/issue1852c/sub/repo (glob) | |
675 | searching for changes |
|
675 | searching for changes | |
676 | no changes found |
|
676 | no changes found | |
677 | searching for changes |
|
677 | searching for changes | |
678 | adding changesets |
|
678 | adding changesets | |
679 | adding manifests |
|
679 | adding manifests | |
680 | adding file changes |
|
680 | adding file changes | |
681 | added 1 changesets with 1 changes to 1 files |
|
681 | added 1 changesets with 1 changes to 1 files | |
682 |
|
682 | |||
683 | Incoming and outgoing should not use the default path: |
|
683 | Incoming and outgoing should not use the default path: | |
684 |
|
684 | |||
685 | $ hg clone -q issue1852a issue1852d |
|
685 | $ hg clone -q issue1852a issue1852d | |
686 | $ hg -R issue1852d outgoing --subrepos issue1852c |
|
686 | $ hg -R issue1852d outgoing --subrepos issue1852c | |
687 | comparing with issue1852c |
|
687 | comparing with issue1852c | |
688 | searching for changes |
|
688 | searching for changes | |
689 | no changes found |
|
689 | no changes found | |
690 | comparing with issue1852c/sub/repo |
|
690 | comparing with issue1852c/sub/repo | |
691 | searching for changes |
|
691 | searching for changes | |
692 | no changes found |
|
692 | no changes found | |
693 | [1] |
|
693 | [1] | |
694 | $ hg -R issue1852d incoming --subrepos issue1852c |
|
694 | $ hg -R issue1852d incoming --subrepos issue1852c | |
695 | comparing with issue1852c |
|
695 | comparing with issue1852c | |
696 | searching for changes |
|
696 | searching for changes | |
697 | no changes found |
|
697 | no changes found | |
698 | comparing with issue1852c/sub/repo |
|
698 | comparing with issue1852c/sub/repo | |
699 | searching for changes |
|
699 | searching for changes | |
700 | no changes found |
|
700 | no changes found | |
701 | [1] |
|
701 | [1] | |
702 |
|
702 | |||
703 | Check status of files when none of them belong to the first |
|
703 | Check status of files when none of them belong to the first | |
704 | subrepository: |
|
704 | subrepository: | |
705 |
|
705 | |||
706 | $ hg init subrepo-status |
|
706 | $ hg init subrepo-status | |
707 | $ cd subrepo-status |
|
707 | $ cd subrepo-status | |
708 | $ hg init subrepo-1 |
|
708 | $ hg init subrepo-1 | |
709 | $ hg init subrepo-2 |
|
709 | $ hg init subrepo-2 | |
710 | $ cd subrepo-2 |
|
710 | $ cd subrepo-2 | |
711 | $ touch file |
|
711 | $ touch file | |
712 | $ hg add file |
|
712 | $ hg add file | |
713 | $ cd .. |
|
713 | $ cd .. | |
714 | $ echo subrepo-1 = subrepo-1 > .hgsub |
|
714 | $ echo subrepo-1 = subrepo-1 > .hgsub | |
715 | $ echo subrepo-2 = subrepo-2 >> .hgsub |
|
715 | $ echo subrepo-2 = subrepo-2 >> .hgsub | |
716 | $ hg add .hgsub |
|
716 | $ hg add .hgsub | |
717 | $ hg ci -m 'Added subrepos' |
|
717 | $ hg ci -m 'Added subrepos' | |
718 | committing subrepository subrepo-2 |
|
718 | committing subrepository subrepo-2 | |
719 | $ hg st subrepo-2/file |
|
719 | $ hg st subrepo-2/file | |
720 |
|
720 | |||
721 | Check hg update --clean |
|
721 | Check hg update --clean | |
722 | $ cd $TESTTMP/t |
|
722 | $ cd $TESTTMP/t | |
723 | $ rm -r t/t.orig |
|
723 | $ rm -r t/t.orig | |
724 | $ hg status -S --all |
|
724 | $ hg status -S --all | |
725 | C .hgsub |
|
725 | C .hgsub | |
726 | C .hgsubstate |
|
726 | C .hgsubstate | |
727 | C a |
|
727 | C a | |
728 | C s/.hgsub |
|
728 | C s/.hgsub | |
729 | C s/.hgsubstate |
|
729 | C s/.hgsubstate | |
730 | C s/a |
|
730 | C s/a | |
731 | C s/ss/a |
|
731 | C s/ss/a | |
732 | C t/t |
|
732 | C t/t | |
733 | $ echo c1 > s/a |
|
733 | $ echo c1 > s/a | |
734 | $ cd s |
|
734 | $ cd s | |
735 | $ echo c1 > b |
|
735 | $ echo c1 > b | |
736 | $ echo c1 > c |
|
736 | $ echo c1 > c | |
737 | $ hg add b |
|
737 | $ hg add b | |
738 | $ cd .. |
|
738 | $ cd .. | |
739 | $ hg status -S |
|
739 | $ hg status -S | |
740 | M s/a |
|
740 | M s/a | |
741 | A s/b |
|
741 | A s/b | |
742 | ? s/c |
|
742 | ? s/c | |
743 | $ hg update -C |
|
743 | $ hg update -C | |
744 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
744 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
745 | $ hg status -S |
|
745 | $ hg status -S | |
746 | ? s/b |
|
746 | ? s/b | |
747 | ? s/c |
|
747 | ? s/c | |
748 |
|
748 | |||
749 | Sticky subrepositories, no changes |
|
749 | Sticky subrepositories, no changes | |
750 | $ cd $TESTTMP/t |
|
750 | $ cd $TESTTMP/t | |
751 | $ hg id |
|
751 | $ hg id | |
752 | 925c17564ef8 tip |
|
752 | 925c17564ef8 tip | |
753 | $ hg -R s id |
|
753 | $ hg -R s id | |
754 | 12a213df6fa9 tip |
|
754 | 12a213df6fa9 tip | |
755 | $ hg -R t id |
|
755 | $ hg -R t id | |
756 | 52c0adc0515a tip |
|
756 | 52c0adc0515a tip | |
757 | $ hg update 11 |
|
757 | $ hg update 11 | |
758 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
758 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
759 | $ hg id |
|
759 | $ hg id | |
760 | 365661e5936a |
|
760 | 365661e5936a | |
761 | $ hg -R s id |
|
761 | $ hg -R s id | |
762 | fc627a69481f |
|
762 | fc627a69481f | |
763 | $ hg -R t id |
|
763 | $ hg -R t id | |
764 | e95bcfa18a35 |
|
764 | e95bcfa18a35 | |
765 |
|
765 | |||
766 | Sticky subrepositorys, file changes |
|
766 | Sticky subrepositorys, file changes | |
767 | $ touch s/f1 |
|
767 | $ touch s/f1 | |
768 | $ touch t/f1 |
|
768 | $ touch t/f1 | |
769 | $ hg add -S s/f1 |
|
769 | $ hg add -S s/f1 | |
770 | $ hg add -S t/f1 |
|
770 | $ hg add -S t/f1 | |
771 | $ hg id |
|
771 | $ hg id | |
772 | 365661e5936a+ |
|
772 | 365661e5936a+ | |
773 | $ hg -R s id |
|
773 | $ hg -R s id | |
774 | fc627a69481f+ |
|
774 | fc627a69481f+ | |
775 | $ hg -R t id |
|
775 | $ hg -R t id | |
776 | e95bcfa18a35+ |
|
776 | e95bcfa18a35+ | |
777 | $ hg update tip |
|
777 | $ hg update tip | |
778 | subrepository sources for s differ |
|
778 | subrepository sources for s differ | |
779 | use (l)ocal source (fc627a69481f) or (r)emote source (12a213df6fa9)? |
|
779 | use (l)ocal source (fc627a69481f) or (r)emote source (12a213df6fa9)? | |
780 | l |
|
780 | l | |
781 | subrepository sources for t differ |
|
781 | subrepository sources for t differ | |
782 | use (l)ocal source (e95bcfa18a35) or (r)emote source (52c0adc0515a)? |
|
782 | use (l)ocal source (e95bcfa18a35) or (r)emote source (52c0adc0515a)? | |
783 | l |
|
783 | l | |
784 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
784 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
785 | $ hg id |
|
785 | $ hg id | |
786 | 925c17564ef8+ tip |
|
786 | 925c17564ef8+ tip | |
787 | $ hg -R s id |
|
787 | $ hg -R s id | |
788 | fc627a69481f+ |
|
788 | fc627a69481f+ | |
789 | $ hg -R t id |
|
789 | $ hg -R t id | |
790 | e95bcfa18a35+ |
|
790 | e95bcfa18a35+ | |
791 | $ hg update --clean tip |
|
791 | $ hg update --clean tip | |
792 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
792 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
793 |
|
793 | |||
794 | Sticky subrepository, revision updates |
|
794 | Sticky subrepository, revision updates | |
795 | $ hg id |
|
795 | $ hg id | |
796 | 925c17564ef8 tip |
|
796 | 925c17564ef8 tip | |
797 | $ hg -R s id |
|
797 | $ hg -R s id | |
798 | 12a213df6fa9 tip |
|
798 | 12a213df6fa9 tip | |
799 | $ hg -R t id |
|
799 | $ hg -R t id | |
800 | 52c0adc0515a tip |
|
800 | 52c0adc0515a tip | |
801 | $ cd s |
|
801 | $ cd s | |
802 | $ hg update -r -2 |
|
802 | $ hg update -r -2 | |
803 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
803 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
804 | $ cd ../t |
|
804 | $ cd ../t | |
805 | $ hg update -r 2 |
|
805 | $ hg update -r 2 | |
806 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
806 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
807 | $ cd .. |
|
807 | $ cd .. | |
808 | $ hg update 10 |
|
808 | $ hg update 10 | |
809 | subrepository sources for t differ (in checked out version) |
|
809 | subrepository sources for t differ (in checked out version) | |
810 | use (l)ocal source (7af322bc1198) or (r)emote source (20a0db6fbf6c)? |
|
810 | use (l)ocal source (7af322bc1198) or (r)emote source (20a0db6fbf6c)? | |
811 | l |
|
811 | l | |
812 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
812 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
813 | $ hg id |
|
813 | $ hg id | |
814 | e45c8b14af55+ |
|
814 | e45c8b14af55+ | |
815 | $ hg -R s id |
|
815 | $ hg -R s id | |
816 | 02dcf1d70411 |
|
816 | 02dcf1d70411 | |
817 | $ hg -R t id |
|
817 | $ hg -R t id | |
818 | 7af322bc1198 |
|
818 | 7af322bc1198 | |
819 |
|
819 | |||
820 | Sticky subrepository, file changes and revision updates |
|
820 | Sticky subrepository, file changes and revision updates | |
821 | $ touch s/f1 |
|
821 | $ touch s/f1 | |
822 | $ touch t/f1 |
|
822 | $ touch t/f1 | |
823 | $ hg add -S s/f1 |
|
823 | $ hg add -S s/f1 | |
824 | $ hg add -S t/f1 |
|
824 | $ hg add -S t/f1 | |
825 | $ hg id |
|
825 | $ hg id | |
826 | e45c8b14af55+ |
|
826 | e45c8b14af55+ | |
827 | $ hg -R s id |
|
827 | $ hg -R s id | |
828 | 02dcf1d70411+ |
|
828 | 02dcf1d70411+ | |
829 | $ hg -R t id |
|
829 | $ hg -R t id | |
830 | 7af322bc1198+ |
|
830 | 7af322bc1198+ | |
831 | $ hg update tip |
|
831 | $ hg update tip | |
832 | subrepository sources for s differ |
|
832 | subrepository sources for s differ | |
833 | use (l)ocal source (02dcf1d70411) or (r)emote source (12a213df6fa9)? |
|
833 | use (l)ocal source (02dcf1d70411) or (r)emote source (12a213df6fa9)? | |
834 | l |
|
834 | l | |
835 | subrepository sources for t differ |
|
835 | subrepository sources for t differ | |
836 | use (l)ocal source (7af322bc1198) or (r)emote source (52c0adc0515a)? |
|
836 | use (l)ocal source (7af322bc1198) or (r)emote source (52c0adc0515a)? | |
837 | l |
|
837 | l | |
838 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
838 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
839 | $ hg id |
|
839 | $ hg id | |
840 | 925c17564ef8+ tip |
|
840 | 925c17564ef8+ tip | |
841 | $ hg -R s id |
|
841 | $ hg -R s id | |
842 | 02dcf1d70411+ |
|
842 | 02dcf1d70411+ | |
843 | $ hg -R t id |
|
843 | $ hg -R t id | |
844 | 7af322bc1198+ |
|
844 | 7af322bc1198+ | |
845 |
|
845 | |||
846 | Sticky repository, update --clean |
|
846 | Sticky repository, update --clean | |
847 | $ hg update --clean tip |
|
847 | $ hg update --clean tip | |
848 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
848 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
849 | $ hg id |
|
849 | $ hg id | |
850 | 925c17564ef8 tip |
|
850 | 925c17564ef8 tip | |
851 | $ hg -R s id |
|
851 | $ hg -R s id | |
852 | 12a213df6fa9 tip |
|
852 | 12a213df6fa9 tip | |
853 | $ hg -R t id |
|
853 | $ hg -R t id | |
854 | 52c0adc0515a tip |
|
854 | 52c0adc0515a tip | |
855 |
|
855 | |||
856 | Test subrepo already at intended revision: |
|
856 | Test subrepo already at intended revision: | |
857 | $ cd s |
|
857 | $ cd s | |
858 | $ hg update fc627a69481f |
|
858 | $ hg update fc627a69481f | |
859 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
859 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
860 | $ cd .. |
|
860 | $ cd .. | |
861 | $ hg update 11 |
|
861 | $ hg update 11 | |
862 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
862 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
863 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
863 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
864 | $ hg id -n |
|
864 | $ hg id -n | |
865 | 11+ |
|
865 | 11+ | |
866 | $ hg -R s id |
|
866 | $ hg -R s id | |
867 | fc627a69481f |
|
867 | fc627a69481f | |
868 | $ hg -R t id |
|
868 | $ hg -R t id | |
869 | e95bcfa18a35 |
|
869 | e95bcfa18a35 | |
870 |
|
870 | |||
871 | Test that removing .hgsubstate doesn't break anything: |
|
871 | Test that removing .hgsubstate doesn't break anything: | |
872 |
|
872 | |||
873 | $ hg rm -f .hgsubstate |
|
873 | $ hg rm -f .hgsubstate | |
874 | $ hg ci -mrm |
|
874 | $ hg ci -mrm | |
875 | nothing changed |
|
875 | nothing changed | |
876 | [1] |
|
876 | [1] | |
877 | $ hg log -vr tip |
|
877 | $ hg log -vr tip | |
878 | changeset: 13:925c17564ef8 |
|
878 | changeset: 13:925c17564ef8 | |
879 | tag: tip |
|
879 | tag: tip | |
880 | user: test |
|
880 | user: test | |
881 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
881 | date: Thu Jan 01 00:00:00 1970 +0000 | |
882 | files: .hgsubstate |
|
882 | files: .hgsubstate | |
883 | description: |
|
883 | description: | |
884 | 13 |
|
884 | 13 | |
885 |
|
885 | |||
886 |
|
886 | |||
887 |
|
887 | |||
888 | Test that removing .hgsub removes .hgsubstate: |
|
888 | Test that removing .hgsub removes .hgsubstate: | |
889 |
|
889 | |||
890 | $ hg rm .hgsub |
|
890 | $ hg rm .hgsub | |
891 | $ hg ci -mrm2 |
|
891 | $ hg ci -mrm2 | |
892 | created new head |
|
892 | created new head | |
893 | $ hg log -vr tip |
|
893 | $ hg log -vr tip | |
894 | changeset: 14:2400bccd50af |
|
894 | changeset: 14:2400bccd50af | |
895 | tag: tip |
|
895 | tag: tip | |
896 | parent: 11:365661e5936a |
|
896 | parent: 11:365661e5936a | |
897 | user: test |
|
897 | user: test | |
898 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
898 | date: Thu Jan 01 00:00:00 1970 +0000 | |
899 | files: .hgsub .hgsubstate |
|
899 | files: .hgsub .hgsubstate | |
900 | description: |
|
900 | description: | |
901 | rm2 |
|
901 | rm2 | |
902 |
|
902 | |||
903 |
|
903 | |||
904 | Test issue3153: diff -S with deleted subrepos |
|
904 | Test issue3153: diff -S with deleted subrepos | |
905 |
|
905 | |||
906 | $ hg diff --nodates -S -c . |
|
906 | $ hg diff --nodates -S -c . | |
907 | diff -r 365661e5936a -r 2400bccd50af .hgsub |
|
907 | diff -r 365661e5936a -r 2400bccd50af .hgsub | |
908 | --- a/.hgsub |
|
908 | --- a/.hgsub | |
909 | +++ /dev/null |
|
909 | +++ /dev/null | |
910 | @@ -1,2 +0,0 @@ |
|
910 | @@ -1,2 +0,0 @@ | |
911 | -s = s |
|
911 | -s = s | |
912 | -t = t |
|
912 | -t = t | |
913 | diff -r 365661e5936a -r 2400bccd50af .hgsubstate |
|
913 | diff -r 365661e5936a -r 2400bccd50af .hgsubstate | |
914 | --- a/.hgsubstate |
|
914 | --- a/.hgsubstate | |
915 | +++ /dev/null |
|
915 | +++ /dev/null | |
916 | @@ -1,2 +0,0 @@ |
|
916 | @@ -1,2 +0,0 @@ | |
917 | -fc627a69481fcbe5f1135069e8a3881c023e4cf5 s |
|
917 | -fc627a69481fcbe5f1135069e8a3881c023e4cf5 s | |
918 | -e95bcfa18a358dc4936da981ebf4147b4cad1362 t |
|
918 | -e95bcfa18a358dc4936da981ebf4147b4cad1362 t | |
919 |
|
919 | |||
920 | Test behavior of add for explicit path in subrepo: |
|
920 | Test behavior of add for explicit path in subrepo: | |
921 | $ cd .. |
|
921 | $ cd .. | |
922 | $ hg init explicit |
|
922 | $ hg init explicit | |
923 | $ cd explicit |
|
923 | $ cd explicit | |
924 | $ echo s = s > .hgsub |
|
924 | $ echo s = s > .hgsub | |
925 | $ hg add .hgsub |
|
925 | $ hg add .hgsub | |
926 | $ hg init s |
|
926 | $ hg init s | |
927 | $ hg ci -m0 |
|
927 | $ hg ci -m0 | |
928 | Adding with an explicit path in a subrepo adds the file |
|
928 | Adding with an explicit path in a subrepo adds the file | |
929 | $ echo c1 > f1 |
|
929 | $ echo c1 > f1 | |
930 | $ echo c2 > s/f2 |
|
930 | $ echo c2 > s/f2 | |
931 | $ hg st -S |
|
931 | $ hg st -S | |
932 | ? f1 |
|
932 | ? f1 | |
933 | ? s/f2 |
|
933 | ? s/f2 | |
934 | $ hg add s/f2 |
|
934 | $ hg add s/f2 | |
935 | $ hg st -S |
|
935 | $ hg st -S | |
936 | A s/f2 |
|
936 | A s/f2 | |
937 | ? f1 |
|
937 | ? f1 | |
938 | $ hg ci -R s -m0 |
|
938 | $ hg ci -R s -m0 | |
939 | $ hg ci -Am1 |
|
939 | $ hg ci -Am1 | |
940 | adding f1 |
|
940 | adding f1 | |
941 | Adding with an explicit path in a subrepo with -S has the same behavior |
|
941 | Adding with an explicit path in a subrepo with -S has the same behavior | |
942 | $ echo c3 > f3 |
|
942 | $ echo c3 > f3 | |
943 | $ echo c4 > s/f4 |
|
943 | $ echo c4 > s/f4 | |
944 | $ hg st -S |
|
944 | $ hg st -S | |
945 | ? f3 |
|
945 | ? f3 | |
946 | ? s/f4 |
|
946 | ? s/f4 | |
947 | $ hg add -S s/f4 |
|
947 | $ hg add -S s/f4 | |
948 | $ hg st -S |
|
948 | $ hg st -S | |
949 | A s/f4 |
|
949 | A s/f4 | |
950 | ? f3 |
|
950 | ? f3 | |
951 | $ hg ci -R s -m1 |
|
951 | $ hg ci -R s -m1 | |
952 | $ hg ci -Ama2 |
|
952 | $ hg ci -Ama2 | |
953 | adding f3 |
|
953 | adding f3 | |
954 | Adding without a path or pattern silently ignores subrepos |
|
954 | Adding without a path or pattern silently ignores subrepos | |
955 | $ echo c5 > f5 |
|
955 | $ echo c5 > f5 | |
956 | $ echo c6 > s/f6 |
|
956 | $ echo c6 > s/f6 | |
957 | $ echo c7 > s/f7 |
|
957 | $ echo c7 > s/f7 | |
958 | $ hg st -S |
|
958 | $ hg st -S | |
959 | ? f5 |
|
959 | ? f5 | |
960 | ? s/f6 |
|
960 | ? s/f6 | |
961 | ? s/f7 |
|
961 | ? s/f7 | |
962 | $ hg add |
|
962 | $ hg add | |
963 | adding f5 |
|
963 | adding f5 | |
964 | $ hg st -S |
|
964 | $ hg st -S | |
965 | A f5 |
|
965 | A f5 | |
966 | ? s/f6 |
|
966 | ? s/f6 | |
967 | ? s/f7 |
|
967 | ? s/f7 | |
968 | $ hg ci -R s -Am2 |
|
968 | $ hg ci -R s -Am2 | |
969 | adding f6 |
|
969 | adding f6 | |
970 | adding f7 |
|
970 | adding f7 | |
971 | $ hg ci -m3 |
|
971 | $ hg ci -m3 | |
972 | Adding without a path or pattern with -S also adds files in subrepos |
|
972 | Adding without a path or pattern with -S also adds files in subrepos | |
973 | $ echo c8 > f8 |
|
973 | $ echo c8 > f8 | |
974 | $ echo c9 > s/f9 |
|
974 | $ echo c9 > s/f9 | |
975 | $ echo c10 > s/f10 |
|
975 | $ echo c10 > s/f10 | |
976 | $ hg st -S |
|
976 | $ hg st -S | |
977 | ? f8 |
|
977 | ? f8 | |
978 | ? s/f10 |
|
978 | ? s/f10 | |
979 | ? s/f9 |
|
979 | ? s/f9 | |
980 | $ hg add -S |
|
980 | $ hg add -S | |
981 | adding f8 |
|
981 | adding f8 | |
982 | adding s/f10 (glob) |
|
982 | adding s/f10 (glob) | |
983 | adding s/f9 (glob) |
|
983 | adding s/f9 (glob) | |
984 | $ hg st -S |
|
984 | $ hg st -S | |
985 | A f8 |
|
985 | A f8 | |
986 | A s/f10 |
|
986 | A s/f10 | |
987 | A s/f9 |
|
987 | A s/f9 | |
988 | $ hg ci -R s -m3 |
|
988 | $ hg ci -R s -m3 | |
989 | $ hg ci -m4 |
|
989 | $ hg ci -m4 | |
990 | Adding with a pattern silently ignores subrepos |
|
990 | Adding with a pattern silently ignores subrepos | |
991 | $ echo c11 > fm11 |
|
991 | $ echo c11 > fm11 | |
992 | $ echo c12 > fn12 |
|
992 | $ echo c12 > fn12 | |
993 | $ echo c13 > s/fm13 |
|
993 | $ echo c13 > s/fm13 | |
994 | $ echo c14 > s/fn14 |
|
994 | $ echo c14 > s/fn14 | |
995 | $ hg st -S |
|
995 | $ hg st -S | |
996 | ? fm11 |
|
996 | ? fm11 | |
997 | ? fn12 |
|
997 | ? fn12 | |
998 | ? s/fm13 |
|
998 | ? s/fm13 | |
999 | ? s/fn14 |
|
999 | ? s/fn14 | |
1000 | $ hg add 'glob:**fm*' |
|
1000 | $ hg add 'glob:**fm*' | |
1001 | adding fm11 |
|
1001 | adding fm11 | |
1002 | $ hg st -S |
|
1002 | $ hg st -S | |
1003 | A fm11 |
|
1003 | A fm11 | |
1004 | ? fn12 |
|
1004 | ? fn12 | |
1005 | ? s/fm13 |
|
1005 | ? s/fm13 | |
1006 | ? s/fn14 |
|
1006 | ? s/fn14 | |
1007 | $ hg ci -R s -Am4 |
|
1007 | $ hg ci -R s -Am4 | |
1008 | adding fm13 |
|
1008 | adding fm13 | |
1009 | adding fn14 |
|
1009 | adding fn14 | |
1010 | $ hg ci -Am5 |
|
1010 | $ hg ci -Am5 | |
1011 | adding fn12 |
|
1011 | adding fn12 | |
1012 | Adding with a pattern with -S also adds matches in subrepos |
|
1012 | Adding with a pattern with -S also adds matches in subrepos | |
1013 | $ echo c15 > fm15 |
|
1013 | $ echo c15 > fm15 | |
1014 | $ echo c16 > fn16 |
|
1014 | $ echo c16 > fn16 | |
1015 | $ echo c17 > s/fm17 |
|
1015 | $ echo c17 > s/fm17 | |
1016 | $ echo c18 > s/fn18 |
|
1016 | $ echo c18 > s/fn18 | |
1017 | $ hg st -S |
|
1017 | $ hg st -S | |
1018 | ? fm15 |
|
1018 | ? fm15 | |
1019 | ? fn16 |
|
1019 | ? fn16 | |
1020 | ? s/fm17 |
|
1020 | ? s/fm17 | |
1021 | ? s/fn18 |
|
1021 | ? s/fn18 | |
1022 | $ hg add -S 'glob:**fm*' |
|
1022 | $ hg add -S 'glob:**fm*' | |
1023 | adding fm15 |
|
1023 | adding fm15 | |
1024 | adding s/fm17 (glob) |
|
1024 | adding s/fm17 (glob) | |
1025 | $ hg st -S |
|
1025 | $ hg st -S | |
1026 | A fm15 |
|
1026 | A fm15 | |
1027 | A s/fm17 |
|
1027 | A s/fm17 | |
1028 | ? fn16 |
|
1028 | ? fn16 | |
1029 | ? s/fn18 |
|
1029 | ? s/fn18 | |
1030 | $ hg ci -R s -Am5 |
|
1030 | $ hg ci -R s -Am5 | |
1031 | adding fn18 |
|
1031 | adding fn18 | |
1032 | $ hg ci -Am6 |
|
1032 | $ hg ci -Am6 | |
1033 | adding fn16 |
|
1033 | adding fn16 | |
1034 |
|
1034 | |||
1035 | Test behavior of forget for explicit path in subrepo: |
|
1035 | Test behavior of forget for explicit path in subrepo: | |
1036 | Forgetting an explicit path in a subrepo untracks the file |
|
1036 | Forgetting an explicit path in a subrepo untracks the file | |
1037 | $ echo c19 > s/f19 |
|
1037 | $ echo c19 > s/f19 | |
1038 | $ hg add s/f19 |
|
1038 | $ hg add s/f19 | |
1039 | $ hg st -S |
|
1039 | $ hg st -S | |
1040 | A s/f19 |
|
1040 | A s/f19 | |
1041 | $ hg forget s/f19 |
|
1041 | $ hg forget s/f19 | |
1042 | $ hg st -S |
|
1042 | $ hg st -S | |
1043 | ? s/f19 |
|
1043 | ? s/f19 | |
1044 | $ rm s/f19 |
|
1044 | $ rm s/f19 | |
1045 | $ cd .. |
|
1045 | $ cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now