Show More
This diff has been collapsed as it changes many lines, (510 lines changed) Show them Hide them | |||||
@@ -1,54 +1,468 b'' | |||||
1 | #!/bin/sh |
|
1 | $ mkdir test | |
|
2 | $ cd test | |||
|
3 | $ hg init | |||
|
4 | $ for i in 0 1 2 3 4 5 6 7 8; do | |||
|
5 | > echo $i >> foo | |||
|
6 | > hg commit -A -m $i -d "1000000 0" | |||
|
7 | > done | |||
|
8 | adding foo | |||
|
9 | $ hg verify | |||
|
10 | checking changesets | |||
|
11 | checking manifests | |||
|
12 | crosschecking files in changesets and manifests | |||
|
13 | checking files | |||
|
14 | 1 files, 9 changesets, 9 total revisions | |||
|
15 | $ hg serve -p $HGPORT -d --pid-file=hg.pid | |||
|
16 | $ cat hg.pid >> $DAEMON_PIDS | |||
|
17 | $ cd .. | |||
|
18 | ||||
|
19 | $ hg init new | |||
|
20 | ||||
|
21 | http incoming | |||
|
22 | ||||
|
23 | $ hg -R new incoming http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," | |||
|
24 | comparing with http://localhost:$HGPORT/ | |||
|
25 | changeset: 0:9cb21d99fe27 | |||
|
26 | user: test | |||
|
27 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
28 | summary: 0 | |||
|
29 | ||||
|
30 | changeset: 1:d717f5dfad6a | |||
|
31 | user: test | |||
|
32 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
33 | summary: 1 | |||
|
34 | ||||
|
35 | changeset: 2:c0d6b86da426 | |||
|
36 | user: test | |||
|
37 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
38 | summary: 2 | |||
|
39 | ||||
|
40 | changeset: 3:dfacbd43b3fe | |||
|
41 | user: test | |||
|
42 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
43 | summary: 3 | |||
|
44 | ||||
|
45 | changeset: 4:1f3a964b6022 | |||
|
46 | user: test | |||
|
47 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
48 | summary: 4 | |||
|
49 | ||||
|
50 | changeset: 5:c028bcc7a28a | |||
|
51 | user: test | |||
|
52 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
53 | summary: 5 | |||
|
54 | ||||
|
55 | changeset: 6:a0c0095f3389 | |||
|
56 | user: test | |||
|
57 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
58 | summary: 6 | |||
|
59 | ||||
|
60 | changeset: 7:d4be65f4e891 | |||
|
61 | user: test | |||
|
62 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
63 | summary: 7 | |||
|
64 | ||||
|
65 | changeset: 8:92b83e334ef8 | |||
|
66 | tag: tip | |||
|
67 | user: test | |||
|
68 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
69 | summary: 8 | |||
|
70 | ||||
|
71 | $ hg -R new incoming -r 4 http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," | |||
|
72 | comparing with http://localhost:$HGPORT/ | |||
|
73 | changeset: 0:9cb21d99fe27 | |||
|
74 | user: test | |||
|
75 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
76 | summary: 0 | |||
|
77 | ||||
|
78 | changeset: 1:d717f5dfad6a | |||
|
79 | user: test | |||
|
80 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
81 | summary: 1 | |||
|
82 | ||||
|
83 | changeset: 2:c0d6b86da426 | |||
|
84 | user: test | |||
|
85 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
86 | summary: 2 | |||
|
87 | ||||
|
88 | changeset: 3:dfacbd43b3fe | |||
|
89 | user: test | |||
|
90 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
91 | summary: 3 | |||
|
92 | ||||
|
93 | changeset: 4:1f3a964b6022 | |||
|
94 | tag: tip | |||
|
95 | user: test | |||
|
96 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
97 | summary: 4 | |||
|
98 | ||||
|
99 | ||||
|
100 | local incoming | |||
2 |
|
101 | |||
3 | mkdir test |
|
102 | $ hg -R new incoming test | |
4 | cd test |
|
103 | comparing with test | |
5 | hg init |
|
104 | changeset: 0:9cb21d99fe27 | |
6 | for i in 0 1 2 3 4 5 6 7 8; do |
|
105 | user: test | |
7 | echo $i >> foo |
|
106 | date: Mon Jan 12 13:46:40 1970 +0000 | |
8 | hg commit -A -m $i -d "1000000 0" |
|
107 | summary: 0 | |
9 | done |
|
108 | ||
10 | hg verify |
|
109 | changeset: 1:d717f5dfad6a | |
11 | hg serve -p $HGPORT -d --pid-file=hg.pid |
|
110 | user: test | |
12 | cat hg.pid >> $DAEMON_PIDS |
|
111 | date: Mon Jan 12 13:46:40 1970 +0000 | |
13 | cd .. |
|
112 | summary: 1 | |
|
113 | ||||
|
114 | changeset: 2:c0d6b86da426 | |||
|
115 | user: test | |||
|
116 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
117 | summary: 2 | |||
|
118 | ||||
|
119 | changeset: 3:dfacbd43b3fe | |||
|
120 | user: test | |||
|
121 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
122 | summary: 3 | |||
|
123 | ||||
|
124 | changeset: 4:1f3a964b6022 | |||
|
125 | user: test | |||
|
126 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
127 | summary: 4 | |||
|
128 | ||||
|
129 | changeset: 5:c028bcc7a28a | |||
|
130 | user: test | |||
|
131 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
132 | summary: 5 | |||
|
133 | ||||
|
134 | changeset: 6:a0c0095f3389 | |||
|
135 | user: test | |||
|
136 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
137 | summary: 6 | |||
|
138 | ||||
|
139 | changeset: 7:d4be65f4e891 | |||
|
140 | user: test | |||
|
141 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
142 | summary: 7 | |||
|
143 | ||||
|
144 | changeset: 8:92b83e334ef8 | |||
|
145 | tag: tip | |||
|
146 | user: test | |||
|
147 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
148 | summary: 8 | |||
|
149 | ||||
|
150 | $ hg -R new incoming -r 4 test | |||
|
151 | comparing with test | |||
|
152 | changeset: 0:9cb21d99fe27 | |||
|
153 | user: test | |||
|
154 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
155 | summary: 0 | |||
|
156 | ||||
|
157 | changeset: 1:d717f5dfad6a | |||
|
158 | user: test | |||
|
159 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
160 | summary: 1 | |||
|
161 | ||||
|
162 | changeset: 2:c0d6b86da426 | |||
|
163 | user: test | |||
|
164 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
165 | summary: 2 | |||
|
166 | ||||
|
167 | changeset: 3:dfacbd43b3fe | |||
|
168 | user: test | |||
|
169 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
170 | summary: 3 | |||
|
171 | ||||
|
172 | changeset: 4:1f3a964b6022 | |||
|
173 | user: test | |||
|
174 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
175 | summary: 4 | |||
|
176 | ||||
14 |
|
177 | |||
15 | hg init new |
|
178 | limit to 2 changesets | |
16 | # http incoming |
|
179 | ||
17 | hg -R new incoming http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," |
|
180 | $ hg -R new incoming -l 2 test | |
18 | hg -R new incoming -r 4 http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," |
|
181 | comparing with test | |
19 | # local incoming |
|
182 | changeset: 0:9cb21d99fe27 | |
20 | hg -R new incoming test |
|
183 | user: test | |
21 | hg -R new incoming -r 4 test |
|
184 | date: Mon Jan 12 13:46:40 1970 +0000 | |
22 | echo "% limit to 2 changesets" |
|
185 | summary: 0 | |
23 | hg -R new incoming -l 2 test |
|
186 | ||
24 | echo "% limit to 2 changesets, test with -p --git" |
|
187 | changeset: 1:d717f5dfad6a | |
25 | hg -R new incoming -l 2 -p --git test |
|
188 | user: test | |
|
189 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
190 | summary: 1 | |||
|
191 | ||||
|
192 | ||||
|
193 | limit to 2 changesets, test with -p --git | |||
|
194 | ||||
|
195 | $ hg -R new incoming -l 2 -p --git test | |||
|
196 | comparing with test | |||
|
197 | changeset: 0:9cb21d99fe27 | |||
|
198 | user: test | |||
|
199 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
200 | summary: 0 | |||
|
201 | ||||
|
202 | diff --git a/foo b/foo | |||
|
203 | new file mode 100644 | |||
|
204 | --- /dev/null | |||
|
205 | +++ b/foo | |||
|
206 | @@ -0,0 +1,1 @@ | |||
|
207 | +0 | |||
|
208 | ||||
|
209 | changeset: 1:d717f5dfad6a | |||
|
210 | user: test | |||
|
211 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
212 | summary: 1 | |||
|
213 | ||||
|
214 | diff --git a/foo b/foo | |||
|
215 | --- a/foo | |||
|
216 | +++ b/foo | |||
|
217 | @@ -1,1 +1,2 @@ | |||
|
218 | 0 | |||
|
219 | +1 | |||
|
220 | ||||
|
221 | ||||
|
222 | test with --bundle | |||
26 |
|
223 | |||
27 | # test with --bundle |
|
224 | $ hg -R new incoming --bundle test.hg http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," | |
28 | hg -R new incoming --bundle test.hg http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," |
|
225 | comparing with http://localhost:$HGPORT/ | |
29 | hg -R new incoming --bundle test2.hg test |
|
226 | changeset: 0:9cb21d99fe27 | |
|
227 | user: test | |||
|
228 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
229 | summary: 0 | |||
|
230 | ||||
|
231 | changeset: 1:d717f5dfad6a | |||
|
232 | user: test | |||
|
233 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
234 | summary: 1 | |||
|
235 | ||||
|
236 | changeset: 2:c0d6b86da426 | |||
|
237 | user: test | |||
|
238 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
239 | summary: 2 | |||
|
240 | ||||
|
241 | changeset: 3:dfacbd43b3fe | |||
|
242 | user: test | |||
|
243 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
244 | summary: 3 | |||
|
245 | ||||
|
246 | changeset: 4:1f3a964b6022 | |||
|
247 | user: test | |||
|
248 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
249 | summary: 4 | |||
|
250 | ||||
|
251 | changeset: 5:c028bcc7a28a | |||
|
252 | user: test | |||
|
253 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
254 | summary: 5 | |||
|
255 | ||||
|
256 | changeset: 6:a0c0095f3389 | |||
|
257 | user: test | |||
|
258 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
259 | summary: 6 | |||
|
260 | ||||
|
261 | changeset: 7:d4be65f4e891 | |||
|
262 | user: test | |||
|
263 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
264 | summary: 7 | |||
|
265 | ||||
|
266 | changeset: 8:92b83e334ef8 | |||
|
267 | tag: tip | |||
|
268 | user: test | |||
|
269 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
270 | summary: 8 | |||
|
271 | ||||
|
272 | $ hg -R new incoming --bundle test2.hg test | |||
|
273 | comparing with test | |||
|
274 | changeset: 0:9cb21d99fe27 | |||
|
275 | user: test | |||
|
276 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
277 | summary: 0 | |||
|
278 | ||||
|
279 | changeset: 1:d717f5dfad6a | |||
|
280 | user: test | |||
|
281 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
282 | summary: 1 | |||
|
283 | ||||
|
284 | changeset: 2:c0d6b86da426 | |||
|
285 | user: test | |||
|
286 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
287 | summary: 2 | |||
|
288 | ||||
|
289 | changeset: 3:dfacbd43b3fe | |||
|
290 | user: test | |||
|
291 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
292 | summary: 3 | |||
|
293 | ||||
|
294 | changeset: 4:1f3a964b6022 | |||
|
295 | user: test | |||
|
296 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
297 | summary: 4 | |||
|
298 | ||||
|
299 | changeset: 5:c028bcc7a28a | |||
|
300 | user: test | |||
|
301 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
302 | summary: 5 | |||
|
303 | ||||
|
304 | changeset: 6:a0c0095f3389 | |||
|
305 | user: test | |||
|
306 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
307 | summary: 6 | |||
|
308 | ||||
|
309 | changeset: 7:d4be65f4e891 | |||
|
310 | user: test | |||
|
311 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
312 | summary: 7 | |||
|
313 | ||||
|
314 | changeset: 8:92b83e334ef8 | |||
|
315 | tag: tip | |||
|
316 | user: test | |||
|
317 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
318 | summary: 8 | |||
|
319 | ||||
30 |
|
320 | |||
31 | # test the resulting bundles |
|
|||
32 | hg init temp |
|
|||
33 | hg init temp2 |
|
|||
34 | hg -R temp unbundle test.hg |
|
|||
35 | hg -R temp2 unbundle test2.hg |
|
|||
36 | hg -R temp tip |
|
|||
37 | hg -R temp2 tip |
|
|||
38 |
|
321 | |||
39 | rm -r temp temp2 new |
|
322 | test the resulting bundles | |
40 |
|
323 | |||
41 | # test outgoing |
|
324 | $ hg init temp | |
42 | hg clone test test-dev |
|
325 | $ hg init temp2 | |
43 | cd test-dev |
|
326 | $ hg -R temp unbundle test.hg | |
44 | for i in 9 10 11 12 13; do |
|
327 | adding changesets | |
45 | echo $i >> foo |
|
328 | adding manifests | |
46 | hg commit -A -m $i -d "1000000 0" |
|
329 | adding file changes | |
47 | done |
|
330 | added 9 changesets with 9 changes to 1 files | |
48 | hg verify |
|
331 | (run 'hg update' to get a working copy) | |
49 | cd .. |
|
332 | $ hg -R temp2 unbundle test2.hg | |
50 | hg -R test-dev outgoing test |
|
333 | adding changesets | |
51 | echo "% limit to 3 changesets" |
|
334 | adding manifests | |
52 | hg -R test-dev outgoing -l 3 test |
|
335 | adding file changes | |
53 | hg -R test-dev outgoing http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," |
|
336 | added 9 changesets with 9 changes to 1 files | |
54 | hg -R test-dev outgoing -r 11 http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," |
|
337 | (run 'hg update' to get a working copy) | |
|
338 | $ hg -R temp tip | |||
|
339 | changeset: 8:92b83e334ef8 | |||
|
340 | tag: tip | |||
|
341 | user: test | |||
|
342 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
343 | summary: 8 | |||
|
344 | ||||
|
345 | $ hg -R temp2 tip | |||
|
346 | changeset: 8:92b83e334ef8 | |||
|
347 | tag: tip | |||
|
348 | user: test | |||
|
349 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
350 | summary: 8 | |||
|
351 | ||||
|
352 | ||||
|
353 | $ rm -r temp temp2 new | |||
|
354 | ||||
|
355 | test outgoing | |||
|
356 | ||||
|
357 | $ hg clone test test-dev | |||
|
358 | updating to branch default | |||
|
359 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |||
|
360 | $ cd test-dev | |||
|
361 | $ for i in 9 10 11 12 13; do | |||
|
362 | > echo $i >> foo | |||
|
363 | > hg commit -A -m $i -d "1000000 0" | |||
|
364 | > done | |||
|
365 | $ hg verify | |||
|
366 | checking changesets | |||
|
367 | checking manifests | |||
|
368 | crosschecking files in changesets and manifests | |||
|
369 | checking files | |||
|
370 | 1 files, 14 changesets, 14 total revisions | |||
|
371 | $ cd .. | |||
|
372 | $ hg -R test-dev outgoing test | |||
|
373 | comparing with test | |||
|
374 | searching for changes | |||
|
375 | changeset: 9:3741c3ad1096 | |||
|
376 | user: test | |||
|
377 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
378 | summary: 9 | |||
|
379 | ||||
|
380 | changeset: 10:de4143c8d9a5 | |||
|
381 | user: test | |||
|
382 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
383 | summary: 10 | |||
|
384 | ||||
|
385 | changeset: 11:0e1c188b9a7a | |||
|
386 | user: test | |||
|
387 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
388 | summary: 11 | |||
|
389 | ||||
|
390 | changeset: 12:251354d0fdd3 | |||
|
391 | user: test | |||
|
392 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
393 | summary: 12 | |||
|
394 | ||||
|
395 | changeset: 13:bdaadd969642 | |||
|
396 | tag: tip | |||
|
397 | user: test | |||
|
398 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
399 | summary: 13 | |||
|
400 | ||||
|
401 | ||||
|
402 | limit to 3 changesets | |||
|
403 | ||||
|
404 | $ hg -R test-dev outgoing -l 3 test | |||
|
405 | comparing with test | |||
|
406 | searching for changes | |||
|
407 | changeset: 9:3741c3ad1096 | |||
|
408 | user: test | |||
|
409 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
410 | summary: 9 | |||
|
411 | ||||
|
412 | changeset: 10:de4143c8d9a5 | |||
|
413 | user: test | |||
|
414 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
415 | summary: 10 | |||
|
416 | ||||
|
417 | changeset: 11:0e1c188b9a7a | |||
|
418 | user: test | |||
|
419 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
420 | summary: 11 | |||
|
421 | ||||
|
422 | $ hg -R test-dev outgoing http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," | |||
|
423 | comparing with http://localhost:$HGPORT/ | |||
|
424 | searching for changes | |||
|
425 | changeset: 9:3741c3ad1096 | |||
|
426 | user: test | |||
|
427 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
428 | summary: 9 | |||
|
429 | ||||
|
430 | changeset: 10:de4143c8d9a5 | |||
|
431 | user: test | |||
|
432 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
433 | summary: 10 | |||
|
434 | ||||
|
435 | changeset: 11:0e1c188b9a7a | |||
|
436 | user: test | |||
|
437 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
438 | summary: 11 | |||
|
439 | ||||
|
440 | changeset: 12:251354d0fdd3 | |||
|
441 | user: test | |||
|
442 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
443 | summary: 12 | |||
|
444 | ||||
|
445 | changeset: 13:bdaadd969642 | |||
|
446 | tag: tip | |||
|
447 | user: test | |||
|
448 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
449 | summary: 13 | |||
|
450 | ||||
|
451 | $ hg -R test-dev outgoing -r 11 http://localhost:$HGPORT/ | sed -e "s,:$HGPORT/,:\$HGPORT/," | |||
|
452 | comparing with http://localhost:$HGPORT/ | |||
|
453 | searching for changes | |||
|
454 | changeset: 9:3741c3ad1096 | |||
|
455 | user: test | |||
|
456 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
457 | summary: 9 | |||
|
458 | ||||
|
459 | changeset: 10:de4143c8d9a5 | |||
|
460 | user: test | |||
|
461 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
462 | summary: 10 | |||
|
463 | ||||
|
464 | changeset: 11:0e1c188b9a7a | |||
|
465 | user: test | |||
|
466 | date: Mon Jan 12 13:46:40 1970 +0000 | |||
|
467 | summary: 11 | |||
|
468 |
1 | NO CONTENT: file was removed |
|
NO CONTENT: file was removed |
General Comments 0
You need to be logged in to leave comments.
Login now