Mercurial > hg
annotate tests/test-subrepo-recursion.t @ 17474:f85816af6294
obsolete: add a high level function to create an obsolete marker
This function is designed to be used by all code that creates new
obsolete markers in the local repository.
It is not used by debugobsolete because debugobsolete allows the
use of an unknown hash as argument.
author | Pierre-Yves David <pierre-yves.david@logilab.fr> |
---|---|
date | Fri, 24 Aug 2012 21:16:23 +0200 |
parents | f2719b387380 |
children | 6047947afb6b |
rev | line source |
---|---|
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
1 Create test repository: |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
2 |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
3 $ hg init repo |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
4 $ cd repo |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
5 $ echo x1 > x.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
6 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
7 $ hg init foo |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
8 $ cd foo |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
9 $ echo y1 > y.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
10 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
11 $ hg init bar |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
12 $ cd bar |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
13 $ echo z1 > z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
14 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
15 $ cd .. |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
16 $ echo 'bar = bar' > .hgsub |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
17 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
18 $ cd .. |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
19 $ echo 'foo = foo' > .hgsub |
12270
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
20 |
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
21 Add files --- .hgsub files must go first to trigger subrepos: |
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
22 |
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
23 $ hg add -S .hgsub |
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
24 $ hg add -S foo/.hgsub |
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
25 $ hg add -S foo/bar |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
26 adding foo/bar/z.txt (glob) |
12270
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
27 $ hg add -S |
166b9866580a
add: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12175
diff
changeset
|
28 adding x.txt |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
29 adding foo/y.txt (glob) |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
30 |
12175
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
31 Test recursive status without committing anything: |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
32 |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
33 $ hg status -S |
12175
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
34 A .hgsub |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
35 A foo/.hgsub |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
36 A foo/bar/z.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
37 A foo/y.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
38 A x.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
39 |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
40 Test recursive diff without committing anything: |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
41 |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
42 $ hg diff --nodates -S foo |
12175
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
43 diff -r 000000000000 foo/.hgsub |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
44 --- /dev/null |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
45 +++ b/foo/.hgsub |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
46 @@ -0,0 +1,1 @@ |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
47 +bar = bar |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
48 diff -r 000000000000 foo/y.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
49 --- /dev/null |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
50 +++ b/foo/y.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
51 @@ -0,0 +1,1 @@ |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
52 +y1 |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
53 diff -r 000000000000 foo/bar/z.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
54 --- /dev/null |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
55 +++ b/foo/bar/z.txt |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
56 @@ -0,0 +1,1 @@ |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
57 +z1 |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
58 |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
59 Commits: |
c0a8f9dea0f6
subrepos: handle modified but uncommitted .hgsub
Martin Geisler <mg@lazybytes.net>
parents:
12167
diff
changeset
|
60 |
15321
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
61 $ hg commit -m fails |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
62 abort: uncommitted changes in subrepo foo |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
63 (use --subrepos for recursive commit) |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
64 [255] |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
65 |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
66 The --subrepos flag overwrite the config setting: |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
67 |
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
68 $ hg commit -m 0-0-0 --config ui.commitsubrepos=No --subrepos |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
69 committing subrepository foo |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
70 committing subrepository foo/bar (glob) |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
71 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
72 $ cd foo |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
73 $ echo y2 >> y.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
74 $ hg commit -m 0-1-0 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
75 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
76 $ cd bar |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
77 $ echo z2 >> z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
78 $ hg commit -m 0-1-1 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
79 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
80 $ cd .. |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
81 $ hg commit -m 0-2-1 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
82 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
83 $ cd .. |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
84 $ hg commit -m 1-2-1 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
85 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
86 Change working directory: |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
87 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
88 $ echo y3 >> foo/y.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
89 $ echo z3 >> foo/bar/z.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
90 $ hg status -S |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
91 M foo/bar/z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
92 M foo/y.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
93 $ hg diff --nodates -S |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
94 diff -r d254738c5f5e foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
95 --- a/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
96 +++ b/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
97 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
98 y1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
99 y2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
100 +y3 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
101 diff -r 9647f22de499 foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
102 --- a/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
103 +++ b/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
104 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
105 z1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
106 z2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
107 +z3 |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
108 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
109 Status call crossing repository boundaries: |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
110 |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
111 $ hg status -S foo/bar/z.txt |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
112 M foo/bar/z.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
113 $ hg status -S -I 'foo/?.txt' |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
114 M foo/y.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
115 $ hg status -S -I '**/?.txt' |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
116 M foo/bar/z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
117 M foo/y.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
118 $ hg diff --nodates -S -I '**/?.txt' |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
119 diff -r d254738c5f5e foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
120 --- a/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
121 +++ b/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
122 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
123 y1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
124 y2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
125 +y3 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
126 diff -r 9647f22de499 foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
127 --- a/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
128 +++ b/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
129 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
130 z1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
131 z2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
132 +z3 |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
133 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
134 Status from within a subdirectory: |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
135 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
136 $ mkdir dir |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
137 $ cd dir |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
138 $ echo a1 > a.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
139 $ hg status -S |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
140 M foo/bar/z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
141 M foo/y.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
142 ? dir/a.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
143 $ hg diff --nodates -S |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
144 diff -r d254738c5f5e foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
145 --- a/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
146 +++ b/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
147 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
148 y1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
149 y2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
150 +y3 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
151 diff -r 9647f22de499 foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
152 --- a/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
153 +++ b/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
154 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
155 z1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
156 z2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
157 +z3 |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
158 |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
159 Status with relative path: |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
160 |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
161 $ hg status -S .. |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
162 M ../foo/bar/z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
163 M ../foo/y.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
164 ? a.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
165 $ hg diff --nodates -S .. |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
166 diff -r d254738c5f5e foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
167 --- a/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
168 +++ b/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
169 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
170 y1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
171 y2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
172 +y3 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
173 diff -r 9647f22de499 foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
174 --- a/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
175 +++ b/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
176 @@ -1,2 +1,3 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
177 z1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
178 z2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
179 +z3 |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
180 $ cd .. |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
181 |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
182 Cleanup and final commit: |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
183 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
184 $ rm -r dir |
15321
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
185 $ hg commit --subrepos -m 2-3-2 |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
186 committing subrepository foo |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
187 committing subrepository foo/bar (glob) |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
188 |
15910
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
189 Test explicit path commands within subrepos: add/forget |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
190 $ echo z1 > foo/bar/z2.txt |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
191 $ hg status -S |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
192 ? foo/bar/z2.txt |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
193 $ hg add foo/bar/z2.txt |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
194 $ hg status -S |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
195 A foo/bar/z2.txt |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
196 $ hg forget foo/bar/z2.txt |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
197 $ hg status -S |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
198 ? foo/bar/z2.txt |
16070
f11eee00c652
forget: show warning messages for forgetting in subrepo correctly
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
15912
diff
changeset
|
199 $ hg forget foo/bar/z2.txt |
16540
4fe8eb4a6e2c
tests: add missing accept of native pathname separator
Mads Kiilerich <mads@kiilerich.com>
parents:
16351
diff
changeset
|
200 not removing foo/bar/z2.txt: file is already untracked (glob) |
16070
f11eee00c652
forget: show warning messages for forgetting in subrepo correctly
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
15912
diff
changeset
|
201 [1] |
f11eee00c652
forget: show warning messages for forgetting in subrepo correctly
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
15912
diff
changeset
|
202 $ hg status -S |
f11eee00c652
forget: show warning messages for forgetting in subrepo correctly
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
15912
diff
changeset
|
203 ? foo/bar/z2.txt |
15910
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
204 $ rm foo/bar/z2.txt |
2b8d5c55ae67
tests: add subrepo recursion tests for add/forget with explicit paths
David M. Carr <david@carrclan.us>
parents:
15520
diff
changeset
|
205 |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
206 Log with the relationships between repo and its subrepo: |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
207 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
208 $ hg log --template '{rev}:{node|short} {desc}\n' |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
209 2:1326fa26d0c0 2-3-2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
210 1:4b3c9ff4f66b 1-2-1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
211 0:23376cbba0d8 0-0-0 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
212 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
213 $ hg -R foo log --template '{rev}:{node|short} {desc}\n' |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
214 3:65903cebad86 2-3-2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
215 2:d254738c5f5e 0-2-1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
216 1:8629ce7dcc39 0-1-0 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
217 0:af048e97ade2 0-0-0 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
218 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
219 $ hg -R foo/bar log --template '{rev}:{node|short} {desc}\n' |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
220 2:31ecbdafd357 2-3-2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
221 1:9647f22de499 0-1-1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
222 0:4904098473f9 0-0-0 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
223 |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
224 Status between revisions: |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
225 |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
226 $ hg status -S |
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
227 $ hg status -S --rev 0:1 |
12166
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
228 M .hgsubstate |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
229 M foo/.hgsubstate |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
230 M foo/bar/z.txt |
441a74b8def1
status: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
diff
changeset
|
231 M foo/y.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
232 $ hg diff --nodates -S -I '**/?.txt' --rev 0:1 |
12167
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
233 diff -r af048e97ade2 -r d254738c5f5e foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
234 --- a/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
235 +++ b/foo/y.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
236 @@ -1,1 +1,2 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
237 y1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
238 +y2 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
239 diff -r 4904098473f9 -r 9647f22de499 foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
240 --- a/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
241 +++ b/foo/bar/z.txt |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
242 @@ -1,1 +1,2 @@ |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
243 z1 |
d2c5b0927c28
diff: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12166
diff
changeset
|
244 +z2 |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
245 |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
246 Enable progress extension for archive tests: |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
247 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
248 $ cp $HGRCPATH $HGRCPATH.no-progress |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
249 $ cat >> $HGRCPATH <<EOF |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
250 > [extensions] |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
251 > progress = |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
252 > [progress] |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
253 > assume-tty = 1 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
254 > delay = 0 |
13149
735dd8e8a208
progress using tests: disable time estimates to avoid flakiness
Augie Fackler <durin42@gmail.com>
parents:
13144
diff
changeset
|
255 > format = topic bar number |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
256 > refresh = 0 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
257 > width = 60 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
258 > EOF |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
259 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
260 Test archiving to a directory tree (the doubled lines in the output |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
261 only show up in the test output, not in real usage): |
12323
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
262 |
16350
4f795f5fbb0b
tests: make tests work if directory contains special characters
Thomas Arendsen Hein <thomas@intevation.de>
parents:
16070
diff
changeset
|
263 $ hg archive --subrepos ../archive 2>&1 | "$TESTDIR/filtercr.py" |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
264 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
265 archiving [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
266 archiving [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
267 archiving [=============> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
268 archiving [=============> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
269 archiving [===========================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
270 archiving [===========================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
271 archiving [==========================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
272 archiving [==========================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
273 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
274 archiving (foo) [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
275 archiving (foo) [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
276 archiving (foo) [===========> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
277 archiving (foo) [===========> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
278 archiving (foo) [=======================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
279 archiving (foo) [=======================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
280 archiving (foo) [====================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
281 archiving (foo) [====================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
282 |
15447
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
283 archiving (foo/bar) [ ] 0/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
284 archiving (foo/bar) [ ] 0/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
285 archiving (foo/bar) [================================>] 1/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
286 archiving (foo/bar) [================================>] 1/1 (glob) |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
287 \r (esc) |
12363
8a5b6383ba02
test-subrepo-recursion: sort archive output for portability
Patrick Mezard <pmezard@gmail.com>
parents:
12339
diff
changeset
|
288 $ find ../archive | sort |
12323
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
289 ../archive |
12363
8a5b6383ba02
test-subrepo-recursion: sort archive output for portability
Patrick Mezard <pmezard@gmail.com>
parents:
12339
diff
changeset
|
290 ../archive/.hg_archival.txt |
8a5b6383ba02
test-subrepo-recursion: sort archive output for portability
Patrick Mezard <pmezard@gmail.com>
parents:
12339
diff
changeset
|
291 ../archive/.hgsub |
8a5b6383ba02
test-subrepo-recursion: sort archive output for portability
Patrick Mezard <pmezard@gmail.com>
parents:
12339
diff
changeset
|
292 ../archive/.hgsubstate |
12323
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
293 ../archive/foo |
12363
8a5b6383ba02
test-subrepo-recursion: sort archive output for portability
Patrick Mezard <pmezard@gmail.com>
parents:
12339
diff
changeset
|
294 ../archive/foo/.hgsub |
8a5b6383ba02
test-subrepo-recursion: sort archive output for portability
Patrick Mezard <pmezard@gmail.com>
parents:
12339
diff
changeset
|
295 ../archive/foo/.hgsubstate |
12323
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
296 ../archive/foo/bar |
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
297 ../archive/foo/bar/z.txt |
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
298 ../archive/foo/y.txt |
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
299 ../archive/x.txt |
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
300 |
12339
f85338f509e4
tests: fixup tests using unzip -l
Matt Mackall <mpm@selenic.com>
parents:
12323
diff
changeset
|
301 Test archiving to zip file (unzip output is unstable): |
12323
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
302 |
16350
4f795f5fbb0b
tests: make tests work if directory contains special characters
Thomas Arendsen Hein <thomas@intevation.de>
parents:
16070
diff
changeset
|
303 $ hg archive --subrepos ../archive.zip 2>&1 | "$TESTDIR/filtercr.py" |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
304 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
305 archiving [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
306 archiving [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
307 archiving [=============> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
308 archiving [=============> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
309 archiving [===========================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
310 archiving [===========================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
311 archiving [==========================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
312 archiving [==========================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
313 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
314 archiving (foo) [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
315 archiving (foo) [ ] 0/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
316 archiving (foo) [===========> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
317 archiving (foo) [===========> ] 1/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
318 archiving (foo) [=======================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
319 archiving (foo) [=======================> ] 2/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
320 archiving (foo) [====================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
321 archiving (foo) [====================================>] 3/3 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
322 |
15447
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
323 archiving (foo/bar) [ ] 0/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
324 archiving (foo/bar) [ ] 0/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
325 archiving (foo/bar) [================================>] 1/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
326 archiving (foo/bar) [================================>] 1/1 (glob) |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
327 \r (esc) |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
328 |
15286
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
329 Test archiving a revision that references a subrepo that is not yet |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
330 cloned: |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
331 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
332 $ hg clone -U . ../empty |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
333 $ cd ../empty |
16350
4f795f5fbb0b
tests: make tests work if directory contains special characters
Thomas Arendsen Hein <thomas@intevation.de>
parents:
16070
diff
changeset
|
334 $ hg archive --subrepos -r tip ../archive.tar.gz 2>&1 | "$TESTDIR/filtercr.py" |
15286
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
335 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
336 archiving [ ] 0/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
337 archiving [ ] 0/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
338 archiving [=============> ] 1/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
339 archiving [=============> ] 1/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
340 archiving [===========================> ] 2/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
341 archiving [===========================> ] 2/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
342 archiving [==========================================>] 3/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
343 archiving [==========================================>] 3/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
344 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
345 archiving (foo) [ ] 0/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
346 archiving (foo) [ ] 0/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
347 archiving (foo) [===========> ] 1/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
348 archiving (foo) [===========> ] 1/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
349 archiving (foo) [=======================> ] 2/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
350 archiving (foo) [=======================> ] 2/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
351 archiving (foo) [====================================>] 3/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
352 archiving (foo) [====================================>] 3/3 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
353 |
15447
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
354 archiving (foo/bar) [ ] 0/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
355 archiving (foo/bar) [ ] 0/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
356 archiving (foo/bar) [================================>] 1/1 (glob) |
9910f60a37ee
tests: make (glob) on windows accept \ instead of /
Mads Kiilerich <mads@kiilerich.com>
parents:
15321
diff
changeset
|
357 archiving (foo/bar) [================================>] 1/1 (glob) |
15286
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
358 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
359 cloning subrepo foo from $TESTTMP/repo/foo |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
360 cloning subrepo foo/bar from $TESTTMP/repo/foo/bar (glob) |
15286
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
361 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
362 The newly cloned subrepos contain no working copy: |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
363 |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
364 $ hg -R foo summary |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
365 parent: -1:000000000000 (no revision checked out) |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
366 branch: default |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
367 commit: (clean) |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
368 update: 4 new changesets (update) |
4be845e3932c
subrepo: pull revisions on demand when archiving hg subrepos
Martin Geisler <mg@aragost.com>
parents:
14281
diff
changeset
|
369 |
13144
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
370 Disable progress extension and cleanup: |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
371 |
aae2d5cbde64
subrepo: add progress bar support to archive
Martin Geisler <mg@aragost.com>
parents:
12640
diff
changeset
|
372 $ mv $HGRCPATH.no-progress $HGRCPATH |
12323
f00953d9533c
subrepo: add support for 'hg archive'
Martin Geisler <mg@aragost.com>
parents:
12316
diff
changeset
|
373 |
15287
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
374 Test archiving when there is a directory in the way for a subrepo |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
375 created by archive: |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
376 |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
377 $ hg clone -U . ../almost-empty |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
378 $ cd ../almost-empty |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
379 $ mkdir foo |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
380 $ echo f > foo/f |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
381 $ hg archive --subrepos -r tip archive |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
382 cloning subrepo foo from $TESTTMP/empty/foo |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
383 abort: destination '$TESTTMP/almost-empty/foo' is not empty (glob) |
15287
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
384 [255] |
b3e19c355ca7
subrepo: abort in hgsubrepo._get if the destination is obstructed
Martin Geisler <mg@aragost.com>
parents:
15286
diff
changeset
|
385 |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
386 Clone and test outgoing: |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
387 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
388 $ cd .. |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
389 $ hg clone repo repo2 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
390 updating to branch default |
14281
ccb7240acf32
subrepo: create subrepos using clone instead of pull
Martin Geisler <mg@aragost.com>
parents:
13343
diff
changeset
|
391 cloning subrepo foo from $TESTTMP/repo/foo |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
392 cloning subrepo foo/bar from $TESTTMP/repo/foo/bar (glob) |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
393 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
394 $ cd repo2 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
395 $ hg outgoing -S |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
396 comparing with $TESTTMP/repo (glob) |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
397 searching for changes |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
398 no changes found |
12640
6cc4b14fb76b
tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents:
12591
diff
changeset
|
399 comparing with $TESTTMP/repo/foo |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
400 searching for changes |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
401 no changes found |
12640
6cc4b14fb76b
tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents:
12591
diff
changeset
|
402 comparing with $TESTTMP/repo/foo/bar |
12400
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
403 searching for changes |
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
404 no changes found |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12275
diff
changeset
|
405 [1] |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
406 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
407 Make nested change: |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
408 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
409 $ echo y4 >> foo/y.txt |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
410 $ hg diff --nodates -S |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
411 diff -r 65903cebad86 foo/y.txt |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
412 --- a/foo/y.txt |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
413 +++ b/foo/y.txt |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
414 @@ -1,3 +1,4 @@ |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
415 y1 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
416 y2 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
417 y3 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
418 +y4 |
15321
e174353e8cda
subrepos: abort commit by default if a subrepo is dirty (BC)
Martin Geisler <mg@lazybytes.net>
parents:
15287
diff
changeset
|
419 $ hg commit --subrepos -m 3-4-2 |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
420 committing subrepository foo |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
421 $ hg outgoing -S |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
422 comparing with $TESTTMP/repo (glob) |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
423 searching for changes |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
424 changeset: 3:2655b8ecc4ee |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
425 tag: tip |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
426 user: test |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
427 date: Thu Jan 01 00:00:00 1970 +0000 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
428 summary: 3-4-2 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
429 |
12640
6cc4b14fb76b
tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents:
12591
diff
changeset
|
430 comparing with $TESTTMP/repo/foo |
12272
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
431 searching for changes |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
432 changeset: 4:e96193d6cb36 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
433 tag: tip |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
434 user: test |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
435 date: Thu Jan 01 00:00:00 1970 +0000 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
436 summary: 3-4-2 |
42ecd56399d7
outgoing: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12270
diff
changeset
|
437 |
12640
6cc4b14fb76b
tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents:
12591
diff
changeset
|
438 comparing with $TESTTMP/repo/foo/bar |
12400
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
439 searching for changes |
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
440 no changes found |
12274
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
441 |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
442 |
12274
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
443 Switch to original repo and setup default path: |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
444 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
445 $ cd ../repo |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
446 $ echo '[paths]' >> .hg/hgrc |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
447 $ echo 'default = ../repo2' >> .hg/hgrc |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
448 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
449 Test incoming: |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
450 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
451 $ hg incoming -S |
15520
d6d7b56ec346
tests: add missing '(glob)'s to match '\' in paths in test output on windows
Mads Kiilerich <mads@kiilerich.com>
parents:
15447
diff
changeset
|
452 comparing with $TESTTMP/repo2 (glob) |
12274
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
453 searching for changes |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
454 changeset: 3:2655b8ecc4ee |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
455 tag: tip |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
456 user: test |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
457 date: Thu Jan 01 00:00:00 1970 +0000 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
458 summary: 3-4-2 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
459 |
12640
6cc4b14fb76b
tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents:
12591
diff
changeset
|
460 comparing with $TESTTMP/repo2/foo |
12274
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
461 searching for changes |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
462 changeset: 4:e96193d6cb36 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
463 tag: tip |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
464 user: test |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
465 date: Thu Jan 01 00:00:00 1970 +0000 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
466 summary: 3-4-2 |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
467 |
12640
6cc4b14fb76b
tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents:
12591
diff
changeset
|
468 comparing with $TESTTMP/repo2/foo/bar |
12400
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
469 searching for changes |
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
470 no changes found |
40852b4b910c
incoming/outgoing: Fix recursion on sub repositories
Erik Zielke <ez@aragost.com>
parents:
12376
diff
changeset
|
471 |
12274
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
472 $ hg incoming -S --bundle incoming.hg |
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
473 abort: cannot combine --bundle and --subrepos |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12275
diff
changeset
|
474 [255] |
12274
c02e1ed3d407
incoming: recurse into subrepositories with --subrepos/-S flag
Martin Geisler <mg@lazybytes.net>
parents:
12272
diff
changeset
|
475 |
12275
88a42bf5fa46
test-subrepo-recursion: test missing subrepo
Martin Geisler <mg@lazybytes.net>
parents:
12274
diff
changeset
|
476 Test missing subrepo: |
88a42bf5fa46
test-subrepo-recursion: test missing subrepo
Martin Geisler <mg@lazybytes.net>
parents:
12274
diff
changeset
|
477 |
88a42bf5fa46
test-subrepo-recursion: test missing subrepo
Martin Geisler <mg@lazybytes.net>
parents:
12274
diff
changeset
|
478 $ rm -r foo |
12588
41fa32a6b6f8
test-subrepo-recursion: deleted default arguments
Erik Zielke <ez@aragost.com>
parents:
12587
diff
changeset
|
479 $ hg status -S |
12503
b4711585a455
subrepo: improve lookup error messages
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
12400
diff
changeset
|
480 warning: error "unknown revision '65903cebad86f1a84bd4f1134f62fa7dcb7a1c98'" in subrepository "foo" |
13339
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
481 |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
482 Issue2619: IndexError: list index out of range on hg add with subrepos |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
483 The subrepo must sorts after the explicit filename. |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
484 |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
485 $ cd .. |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
486 $ hg init test |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
487 $ cd test |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
488 $ hg init x |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
489 $ echo "x = x" >> .hgsub |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
490 $ hg add .hgsub |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
491 $ touch a x/a |
22167be007ed
subrepo: fix pruning of subrepo filenames in dirstate (issue2619)
trbs <trbs@trbs.net>
parents:
12640
diff
changeset
|
492 $ hg add a x/a |
16913
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
16540
diff
changeset
|
493 |
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
16540
diff
changeset
|
494 $ cd .. |