Mercurial > hg
annotate tests/test-convert-bzr.t @ 12527:9a0528fd9172
tests: unify test-convert-hg-svn
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Sun, 26 Sep 2010 16:53:06 -0500 |
parents | 8d84166d34d7 |
children | e0348815e806 |
rev | line source |
---|---|
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
1 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
2 $ . "$TESTDIR/bzr-definitions" |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
3 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
4 create and rename on the same file in the same step |
7053 | 5 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
6 $ mkdir test-createandrename |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
7 $ cd test-createandrename |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
8 $ bzr init -q source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
9 $ cd source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
10 $ echo a > a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
11 $ echo c > c |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
12 $ echo e > e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
13 $ bzr add -q a c e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
14 $ bzr commit -q -m 'Initial add: a, c, e' |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
15 $ bzr mv a b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
16 a => b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
17 $ bzr mv c d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
18 c => d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
19 $ bzr mv e f |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
20 e => f |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
21 $ echo a2 >> a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
22 $ mkdir e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
23 $ bzr add -q a e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
24 $ bzr commit -q -m 'rename a into b, create a, rename c into d' |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
25 $ cd .. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
26 $ hg convert source source-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
27 initializing destination source-hg repository |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
28 scanning source... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
29 sorting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
30 converting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
31 1 Initial add: a, c, e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
32 0 rename a into b, create a, rename c into d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
33 $ glog -R source-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
34 o 1 "rename a into b, create a, rename c into d" files: a b c d e f |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
35 | |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
36 o 0 "Initial add: a, c, e" files: a c e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
37 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
38 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
39 manifest |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
40 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
41 $ hg manifest -R source-hg -r tip |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
42 a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
43 b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
44 d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
45 f |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
46 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
47 test --rev option |
7053 | 48 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
49 $ hg convert -r 1 source source-1-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
50 initializing destination source-1-hg repository |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
51 scanning source... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
52 sorting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
53 converting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
54 0 Initial add: a, c, e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
55 $ glog -R source-1-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
56 o 0 "Initial add: a, c, e" files: a c e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
57 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
58 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
59 test with filemap |
8305
7a0fcdd3828f
convert/bzr: handle Bazaar timestamps correctly (issue1652).
Greg Ward <greg-hg@gerg.ca>
parents:
8165
diff
changeset
|
60 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
61 $ cat > filemap <<EOF |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
62 > exclude a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
63 > EOF |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
64 $ hg convert --filemap filemap source source-filemap-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
65 initializing destination source-filemap-hg repository |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
66 scanning source... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
67 sorting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
68 converting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
69 1 Initial add: a, c, e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
70 0 rename a into b, create a, rename c into d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
71 $ hg -R source-filemap-hg manifest -r tip |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
72 b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
73 d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
74 f |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
75 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
76 convert from lightweight checkout |
8470
dd24488cba2d
convert/bzr: warn when source is a lightweight checkout (issue1647)
Patrick Mezard <pmezard@gmail.com>
parents:
8434
diff
changeset
|
77 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
78 $ bzr checkout --lightweight source source-light |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
79 $ hg convert source-light source-light-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
80 initializing destination source-light-hg repository |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
81 warning: lightweight checkouts may cause conversion failures, try with a regular branch instead. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
82 scanning source... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
83 sorting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
84 converting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
85 1 Initial add: a, c, e |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
86 0 rename a into b, create a, rename c into d |
8305
7a0fcdd3828f
convert/bzr: handle Bazaar timestamps correctly (issue1652).
Greg Ward <greg-hg@gerg.ca>
parents:
8165
diff
changeset
|
87 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
88 lightweight manifest |
8305
7a0fcdd3828f
convert/bzr: handle Bazaar timestamps correctly (issue1652).
Greg Ward <greg-hg@gerg.ca>
parents:
8165
diff
changeset
|
89 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
90 $ hg manifest -R source-light-hg -r tip |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
91 a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
92 b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
93 d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
94 f |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
95 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
96 extract timestamps that look just like hg's {date|isodate}: |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
97 yyyy-mm-dd HH:MM zzzz (no seconds!) |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
98 compare timestamps |
7053 | 99 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
100 $ cd source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
101 $ bzr log | \ |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
102 > sed '/timestamp/!d;s/.\{15\}\([0-9: -]\{16\}\):.. \(.[0-9]\{4\}\)/\1 \2/' \ |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
103 > > ../bzr-timestamps |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
104 $ cd .. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
105 $ hg -R source-hg log --template "{date|isodate}\n" > hg-timestamps |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
106 $ diff -u bzr-timestamps hg-timestamps |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
107 $ cd .. |
7053 | 108 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
109 merge |
7053 | 110 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
111 $ mkdir test-merge |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
112 $ cd test-merge |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
113 $ cat > helper.py <<EOF |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
114 > import sys |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
115 > from bzrlib import workingtree |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
116 > wt = workingtree.WorkingTree.open('.') |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
117 > |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
118 > message, stamp = sys.argv[1:] |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
119 > wt.commit(message, timestamp=int(stamp)) |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
120 > EOF |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
121 $ bzr init -q source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
122 $ cd source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
123 $ echo content > a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
124 $ echo content2 > b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
125 $ bzr add -q a b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
126 $ bzr commit -q -m 'Initial add' |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
127 $ cd .. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
128 $ bzr branch -q source source-improve |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
129 $ cd source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
130 $ echo more >> a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
131 $ python ../helper.py 'Editing a' 100 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
132 $ cd ../source-improve |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
133 $ echo content3 >> b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
134 $ python ../helper.py 'Editing b' 200 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
135 $ cd ../source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
136 $ bzr merge -q ../source-improve |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
137 $ bzr commit -q -m 'Merged improve branch' |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
138 $ cd .. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
139 $ hg convert --datesort source source-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
140 initializing destination source-hg repository |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
141 scanning source... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
142 sorting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
143 converting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
144 3 Initial add |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
145 2 Editing a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
146 1 Editing b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
147 0 Merged improve branch |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
148 $ glog -R source-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
149 o 3 "Merged improve branch" files: |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
150 |\ |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
151 | o 2 "Editing b" files: b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
152 | | |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
153 o | 1 "Editing a" files: a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
154 |/ |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
155 o 0 "Initial add" files: a b |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
156 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
157 $ cd .. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
158 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
159 symlinks and executable files |
7053 | 160 |
12512
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
161 $ mkdir test-symlinks |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
162 $ cd test-symlinks |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
163 $ bzr init -q source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
164 $ cd source |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
165 $ touch program |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
166 $ chmod +x program |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
167 $ ln -s program altname |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
168 $ mkdir d |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
169 $ echo a > d/a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
170 $ ln -s a syma |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
171 $ bzr add -q altname program syma d/a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
172 $ bzr commit -q -m 'Initial setup' |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
173 $ touch newprog |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
174 $ chmod +x newprog |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
175 $ rm altname |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
176 $ ln -s newprog altname |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
177 $ chmod -x program |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
178 $ bzr add -q newprog |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
179 $ bzr commit -q -m 'Symlink changed, x bits changed' |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
180 $ cd .. |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
181 $ hg convert source source-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
182 initializing destination source-hg repository |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
183 scanning source... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
184 sorting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
185 converting... |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
186 1 Initial setup |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
187 0 Symlink changed, x bits changed |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
188 $ manifest source-hg 0 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
189 % manifest of 0 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
190 644 @ altname |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
191 644 d/a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
192 755 * program |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
193 644 @ syma |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
194 $ manifest source-hg tip |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
195 % manifest of tip |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
196 644 @ altname |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
197 644 d/a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
198 755 * newprog |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
199 644 program |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
200 644 @ syma |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
201 $ cd source-hg |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
202 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
203 test the symlinks can be recreated |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
204 |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
205 $ hg up |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
206 5 files updated, 0 files merged, 0 files removed, 0 files unresolved |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
207 $ hg cat syma; echo |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
208 a |
8d84166d34d7
tests: unify test-convert-bzr
Matt Mackall <mpm@selenic.com>
parents:
8470
diff
changeset
|
209 |