Mercurial > hg
comparison tests/test-subrepo-git.t @ 13181:413bef846806
subrepo: fix subrelpath for git subrepos
This patch conforms gitsubrepo code to the variable naming scheme of the other
subrepo implementations. All user-facing path references should be relative
to the root repository.
author | Eric Eisner <ede@mit.edu> |
---|---|
date | Mon, 20 Dec 2010 13:59:33 -0500 |
parents | 560b8001f765 |
children | 2537bd17421d |
comparison
equal
deleted
inserted
replaced
13180:a79e0688a5ee | 13181:413bef846806 |
---|---|
32 $ cd ../t | 32 $ cd ../t |
33 $ echo 's = [git]../gitroot' > .hgsub | 33 $ echo 's = [git]../gitroot' > .hgsub |
34 $ git clone -q ../gitroot s | 34 $ git clone -q ../gitroot s |
35 $ hg add .hgsub | 35 $ hg add .hgsub |
36 $ hg commit -m 'new git subrepo' | 36 $ hg commit -m 'new git subrepo' |
37 committing subrepository $TESTTMP/t/s | 37 committing subrepository s |
38 $ hg debugsub | 38 $ hg debugsub |
39 path s | 39 path s |
40 source ../gitroot | 40 source ../gitroot |
41 revision da5f5b1d8ffcf62fb8327bcd3c89a4367a6018e7 | 41 revision da5f5b1d8ffcf62fb8327bcd3c89a4367a6018e7 |
42 | 42 |
51 $ git pull -q >/dev/null 2>/dev/null | 51 $ git pull -q >/dev/null 2>/dev/null |
52 $ git checkout -q -b testing origin/testing >/dev/null | 52 $ git checkout -q -b testing origin/testing >/dev/null |
53 | 53 |
54 $ cd .. | 54 $ cd .. |
55 $ hg commit -m 'update git subrepo' | 55 $ hg commit -m 'update git subrepo' |
56 committing subrepository $TESTTMP/t/s | 56 committing subrepository s |
57 $ hg debugsub | 57 $ hg debugsub |
58 path s | 58 path s |
59 source ../gitroot | 59 source ../gitroot |
60 revision 126f2a14290cd5ce061fdedc430170e8d39e1c5a | 60 revision 126f2a14290cd5ce061fdedc430170e8d39e1c5a |
61 | 61 |
98 3 files updated, 0 files merged, 0 files removed, 0 files unresolved | 98 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
99 | 99 |
100 $ cd ../ta | 100 $ cd ../ta |
101 $ echo ggg >> s/g | 101 $ echo ggg >> s/g |
102 $ hg commit -m ggg | 102 $ hg commit -m ggg |
103 committing subrepository $TESTTMP/ta/s | 103 committing subrepository s |
104 $ hg debugsub | 104 $ hg debugsub |
105 path s | 105 path s |
106 source ../gitroot | 106 source ../gitroot |
107 revision 79695940086840c99328513acbe35f90fcd55e57 | 107 revision 79695940086840c99328513acbe35f90fcd55e57 |
108 | 108 |
118 $ echo f > f | 118 $ echo f > f |
119 $ git add f | 119 $ git add f |
120 $ cd .. | 120 $ cd .. |
121 | 121 |
122 $ hg commit -m f | 122 $ hg commit -m f |
123 committing subrepository $TESTTMP/tb/s | 123 committing subrepository s |
124 $ hg debugsub | 124 $ hg debugsub |
125 path s | 125 path s |
126 source ../gitroot | 126 source ../gitroot |
127 revision aa84837ccfbdfedcdcdeeedc309d73e6eb069edc | 127 revision aa84837ccfbdfedcdcdeeedc309d73e6eb069edc |
128 | 128 |
157 $ cat s/g | 157 $ cat s/g |
158 g | 158 g |
159 gg | 159 gg |
160 ggg | 160 ggg |
161 $ hg commit -m 'merge' | 161 $ hg commit -m 'merge' |
162 committing subrepository $TESTTMP/ta/s | 162 committing subrepository s |
163 $ hg debugsub | 163 $ hg debugsub |
164 path s | 164 path s |
165 source ../gitroot | 165 source ../gitroot |
166 revision f47b465e1bce645dbf37232a00574aa1546ca8d3 | 166 revision f47b465e1bce645dbf37232a00574aa1546ca8d3 |
167 $ hg push 2>/dev/null | 167 $ hg push 2>/dev/null |
210 $ hg pull -u -q | 210 $ hg pull -u -q |
211 $ cd s | 211 $ cd s |
212 $ git pull -q >/dev/null 2>/dev/null | 212 $ git pull -q >/dev/null 2>/dev/null |
213 $ cd .. | 213 $ cd .. |
214 $ hg commit -m 'git upstream sync' | 214 $ hg commit -m 'git upstream sync' |
215 committing subrepository $TESTTMP/ta/s | 215 committing subrepository s |
216 $ hg debugsub | 216 $ hg debugsub |
217 path s | 217 path s |
218 source ../gitroot | 218 source ../gitroot |
219 revision 32a343883b74769118bb1d3b4b1fbf9156f4dddc | 219 revision 32a343883b74769118bb1d3b4b1fbf9156f4dddc |
220 $ hg push -q | 220 $ hg push -q |
258 f | 258 f |
259 $ cat s/g | 259 $ cat s/g |
260 g | 260 g |
261 gg | 261 gg |
262 ggg | 262 ggg |
263 | |
264 create nested repo | |
265 | |
266 $ cd .. | |
267 $ hg init outer | |
268 $ cd outer | |
269 $ echo b>b | |
270 $ hg add b | |
271 $ hg commit -m b | |
272 | |
273 $ hg clone ../t inner | |
274 updating to branch default | |
275 cloning subrepo s | |
276 3 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
277 $ echo inner = inner > .hgsub | |
278 $ hg add .hgsub | |
279 $ hg commit -m 'nested sub' | |
280 committing subrepository inner | |
281 | |
282 nested commit | |
283 | |
284 $ echo ffff >> inner/s/f | |
285 $ hg commit -m nested | |
286 committing subrepository inner | |
287 committing subrepository inner/s | |
288 | |
289 nested archive | |
290 | |
291 $ hg archive --subrepos ../narchive | |
292 $ ls ../narchive/inner/s | |
293 f | |
294 g |