author | Nicolas Dumazet <nicdumz.commits@gmail.com> |
Mon, 30 Aug 2010 13:32:37 +0900 | |
changeset 12106 | 969176bec217 |
parent 12098 | 12108d7f2ce1 |
child 12156 | 4c94b6d0fb1c |
permissions | -rw-r--r-- |
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
1 |
$ hg init |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
2 |
$ mkdir d1 d1/d11 d2 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
3 |
$ echo d1/a > d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
4 |
$ echo d1/ba > d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
5 |
$ echo d1/a1 > d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
6 |
$ echo d1/b > d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
7 |
$ echo d2/b > d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
8 |
$ hg add d1/a d1/b d1/ba d1/d11/a1 d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
9 |
$ hg commit -m "1" -d "1000000 0" |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
10 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
11 |
rename a single file |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
12 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
13 |
$ hg rename d1/d11/a1 d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
14 |
$ hg sum |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
15 |
parent: 0:6f9914c7a010 tip |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
16 |
1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
17 |
branch: default |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
18 |
commit: 1 renamed |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
19 |
update: (current) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
20 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
21 |
A d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
22 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
23 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
24 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
25 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
26 |
$ rm d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
27 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
28 |
rename --after a single file |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
29 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
30 |
$ mv d1/d11/a1 d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
31 |
$ hg rename --after d1/d11/a1 d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
32 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
33 |
A d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
34 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
35 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
36 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
37 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
38 |
$ rm d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
39 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
40 |
rename --after a single file when src and tgt already tracked |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
41 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
42 |
$ mv d1/d11/a1 d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
43 |
$ hg addrem -s 0 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
44 |
removing d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
45 |
adding d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
46 |
$ hg rename --after d1/d11/a1 d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
47 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
48 |
A d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
49 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
50 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
51 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
52 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
53 |
$ rm d2/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
54 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
55 |
rename --after a single file to a nonexistant target filename |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
56 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
57 |
$ hg rename --after d1/a dummy |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
58 |
d1/a: not recording move - dummy does not exist |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
59 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
60 |
move a single file to an existing directory |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
61 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
62 |
$ hg rename d1/d11/a1 d2 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
63 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
64 |
A d2/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
65 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
66 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
67 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
68 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
69 |
$ rm d2/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
70 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
71 |
move --after a single file to an existing directory |
11223
0d09f2244805
rename: make --after work if source is already in R state
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
11152
diff
changeset
|
72 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
73 |
$ mv d1/d11/a1 d2 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
74 |
$ hg rename --after d1/d11/a1 d2 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
75 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
76 |
A d2/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
77 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
78 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
79 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
80 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
81 |
$ rm d2/a1 |
11152
e8d10d085f47
cmdutil: Warn when trying to copy/rename --after to a nonexistant file.
Steve Losh <steve@stevelosh.com>
parents:
10466
diff
changeset
|
82 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
83 |
rename a file using a relative path |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
84 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
85 |
$ (cd d1/d11; hg rename ../../d2/b e) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
86 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
87 |
A d1/d11/e |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
88 |
d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
89 |
R d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
90 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
91 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
92 |
$ rm d1/d11/e |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
93 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
94 |
rename --after a file using a relative path |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
95 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
96 |
$ (cd d1/d11; mv ../../d2/b e; hg rename --after ../../d2/b e) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
97 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
98 |
A d1/d11/e |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
99 |
d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
100 |
R d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
101 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
102 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
103 |
$ rm d1/d11/e |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
104 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
105 |
rename directory d1 as d3 |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
106 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
107 |
$ hg rename d1/ d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
108 |
moving d1/a to d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
109 |
moving d1/b to d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
110 |
moving d1/ba to d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
111 |
moving d1/d11/a1 to d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
112 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
113 |
A d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
114 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
115 |
A d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
116 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
117 |
A d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
118 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
119 |
A d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
120 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
121 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
122 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
123 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
124 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
125 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
126 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
127 |
$ rm -rf d3 |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
128 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
129 |
rename --after directory d1 as d3 |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
130 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
131 |
$ mv d1 d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
132 |
$ hg rename --after d1 d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
133 |
moving d1/a to d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
134 |
moving d1/b to d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
135 |
moving d1/ba to d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
136 |
moving d1/d11/a1 to d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
137 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
138 |
A d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
139 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
140 |
A d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
141 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
142 |
A d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
143 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
144 |
A d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
145 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
146 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
147 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
148 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
149 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
150 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
151 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
152 |
$ rm -rf d3 |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
153 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
154 |
move a directory using a relative path |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
155 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
156 |
$ (cd d2; mkdir d3; hg rename ../d1/d11 d3) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
157 |
moving ../d1/d11/a1 to d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
158 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
159 |
A d2/d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
160 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
161 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
162 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
163 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
164 |
$ rm -rf d2/d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
165 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
166 |
move --after a directory using a relative path |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
167 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
168 |
$ (cd d2; mkdir d3; mv ../d1/d11 d3; hg rename --after ../d1/d11 d3) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
169 |
moving ../d1/d11/a1 to d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
170 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
171 |
A d2/d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
172 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
173 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
174 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
175 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
176 |
$ rm -rf d2/d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
177 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
178 |
move directory d1/d11 to an existing directory d2 (removes empty d1) |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
179 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
180 |
$ hg rename d1/d11/ d2 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
181 |
moving d1/d11/a1 to d2/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
182 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
183 |
A d2/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
184 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
185 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
186 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
187 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
188 |
$ rm -rf d2/d11 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
189 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
190 |
move directories d1 and d2 to a new directory d3 |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
191 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
192 |
$ mkdir d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
193 |
$ hg rename d1 d2 d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
194 |
moving d1/a to d3/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
195 |
moving d1/b to d3/d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
196 |
moving d1/ba to d3/d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
197 |
moving d1/d11/a1 to d3/d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
198 |
moving d2/b to d3/d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
199 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
200 |
A d3/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
201 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
202 |
A d3/d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
203 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
204 |
A d3/d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
205 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
206 |
A d3/d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
207 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
208 |
A d3/d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
209 |
d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
210 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
211 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
212 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
213 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
214 |
R d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
215 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
216 |
5 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
217 |
$ rm -rf d3 |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
218 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
219 |
move --after directories d1 and d2 to a new directory d3 |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
220 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
221 |
$ mkdir d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
222 |
$ mv d1 d2 d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
223 |
$ hg rename --after d1 d2 d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
224 |
moving d1/a to d3/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
225 |
moving d1/b to d3/d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
226 |
moving d1/ba to d3/d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
227 |
moving d1/d11/a1 to d3/d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
228 |
moving d2/b to d3/d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
229 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
230 |
A d3/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
231 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
232 |
A d3/d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
233 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
234 |
A d3/d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
235 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
236 |
A d3/d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
237 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
238 |
A d3/d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
239 |
d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
240 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
241 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
242 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
243 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
244 |
R d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
245 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
246 |
5 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
247 |
$ rm -rf d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
248 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
249 |
move everything under directory d1 to existing directory d2, do not |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
250 |
overwrite existing files (d2/b) |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
251 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
252 |
$ hg rename d1/* d2 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
253 |
d2/b: not overwriting - file exists |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
254 |
moving d1/d11/a1 to d2/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
255 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
256 |
A d2/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
257 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
258 |
A d2/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
259 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
260 |
A d2/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
261 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
262 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
263 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
264 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
265 |
$ diff -u d1/b d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
266 |
--- d1/b .* |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
267 |
\+\+\+ d2/b .* |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
268 |
@@ -1 +1 @@ |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
269 |
-d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
270 |
+d2/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
271 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
272 |
3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
273 |
$ rm d2/a d2/ba d2/d11/a1 |
5329
7e6138cb8d38
copy: if destination ends with "/", make sure it's a directory
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
4742
diff
changeset
|
274 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
275 |
attempt to move one file into a non-existent directory |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
276 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
277 |
$ hg rename d1/a dx/ |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
278 |
abort: destination dx/ is not a directory |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
279 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
280 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
281 |
0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
282 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
283 |
attempt to move potentially more than one file into a non-existent directory |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
284 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
285 |
$ hg rename 'glob:d1/**' dx |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
286 |
abort: with multiple sources, destination must be an existing directory |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
287 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
288 |
move every file under d1 to d2/d21 (glob) |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
289 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
290 |
$ mkdir d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
291 |
$ hg rename 'glob:d1/**' d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
292 |
moving d1/a to d2/d21/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
293 |
moving d1/b to d2/d21/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
294 |
moving d1/ba to d2/d21/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
295 |
moving d1/d11/a1 to d2/d21/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
296 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
297 |
A d2/d21/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
298 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
299 |
A d2/d21/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
300 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
301 |
A d2/d21/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
302 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
303 |
A d2/d21/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
304 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
305 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
306 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
307 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
308 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
309 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
310 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
311 |
$ rm -rf d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
312 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
313 |
move --after some files under d1 to d2/d21 (glob) |
1512
53ad6ee6ede4
generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff
changeset
|
314 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
315 |
$ mkdir d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
316 |
$ mv d1/a d1/d11/a1 d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
317 |
$ hg rename --after 'glob:d1/**' d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
318 |
moving d1/a to d2/d21/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
319 |
d1/b: not recording move - d2/d21/b does not exist |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
320 |
d1/ba: not recording move - d2/d21/ba does not exist |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
321 |
moving d1/d11/a1 to d2/d21/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
322 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
323 |
A d2/d21/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
324 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
325 |
A d2/d21/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
326 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
327 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
328 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
329 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
330 |
2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
331 |
$ rm -rf d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
332 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
333 |
move every file under d1 starting with an 'a' to d2/d21 (regexp) |
1565
4bcbc126b80b
fix rename --after
Robin Farine <robin.farine@terminus.org>
parents:
1515
diff
changeset
|
334 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
335 |
$ mkdir d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
336 |
$ hg rename 're:d1/([^a][^/]*/)*a.*' d2/d21 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
337 |
moving d1/a to d2/d21/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
338 |
moving d1/d11/a1 to d2/d21/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
339 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
340 |
A d2/d21/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
341 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
342 |
A d2/d21/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
343 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
344 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
345 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
346 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
347 |
2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
348 |
$ rm -rf d2/d21 |
1513
5c3b93b244aa
copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents:
1512
diff
changeset
|
349 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
350 |
attempt to overwrite an existing file |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
351 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
352 |
$ echo "ca" > d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
353 |
$ hg rename d1/ba d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
354 |
d1/ca: not overwriting - file exists |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
355 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
356 |
? d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
357 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
358 |
0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
359 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
360 |
forced overwrite of an existing file |
1513
5c3b93b244aa
copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents:
1512
diff
changeset
|
361 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
362 |
$ echo "ca" > d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
363 |
$ hg rename --force d1/ba d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
364 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
365 |
A d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
366 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
367 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
368 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
369 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
370 |
$ rm d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
371 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
372 |
replace a symlink with a file |
1513
5c3b93b244aa
copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents:
1512
diff
changeset
|
373 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
374 |
$ ln -s ba d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
375 |
$ hg rename --force d1/ba d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
376 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
377 |
A d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
378 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
379 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
380 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
381 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
382 |
$ rm d1/ca |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
383 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
384 |
do not copy more than one source file to the same destination file |
1514
faf46d810a85
avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents:
1513
diff
changeset
|
385 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
386 |
$ mkdir d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
387 |
$ hg rename d1/* d2/* d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
388 |
moving d1/d11/a1 to d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
389 |
d3/b: not overwriting - d2/b collides with d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
390 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
391 |
A d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
392 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
393 |
A d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
394 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
395 |
A d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
396 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
397 |
A d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
398 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
399 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
400 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
401 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
402 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
403 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
404 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
405 |
$ rm -rf d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
406 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
407 |
move a whole subtree with \"hg rename .\" |
1633
94c179a92f4a
copy/rename '.' or '..' correctly
Robin Farine <robin.farine@terminus.org>
parents:
1565
diff
changeset
|
408 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
409 |
$ mkdir d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
410 |
$ (cd d1; hg rename . ../d3) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
411 |
moving a to ../d3/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
412 |
moving b to ../d3/d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
413 |
moving ba to ../d3/d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
414 |
moving d11/a1 to ../d3/d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
415 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
416 |
A d3/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
417 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
418 |
A d3/d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
419 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
420 |
A d3/d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
421 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
422 |
A d3/d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
423 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
424 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
425 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
426 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
427 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
428 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
429 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
430 |
$ rm -rf d3 |
1633
94c179a92f4a
copy/rename '.' or '..' correctly
Robin Farine <robin.farine@terminus.org>
parents:
1565
diff
changeset
|
431 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
432 |
move a whole subtree with \"hg rename --after .\" |
1633
94c179a92f4a
copy/rename '.' or '..' correctly
Robin Farine <robin.farine@terminus.org>
parents:
1565
diff
changeset
|
433 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
434 |
$ mkdir d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
435 |
$ mv d1/* d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
436 |
$ (cd d1; hg rename --after . ../d3) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
437 |
moving a to ../d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
438 |
moving b to ../d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
439 |
moving ba to ../d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
440 |
moving d11/a1 to ../d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
441 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
442 |
A d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
443 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
444 |
A d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
445 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
446 |
A d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
447 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
448 |
A d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
449 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
450 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
451 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
452 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
453 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
454 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
455 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
456 |
$ rm -rf d3 |
1634
f49f602fae92
copy & rename can ignore removed source files
Robin Farine <robin.farine@terminus.org>
parents:
1633
diff
changeset
|
457 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
458 |
move the parent tree with \"hg rename ..\" |
1747
91c56c427171
transitive copy/rename
Robin Farine <robin.farine@terminus.org>
parents:
1634
diff
changeset
|
459 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
460 |
$ (cd d1/d11; hg rename .. ../../d3) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
461 |
moving ../a to ../../d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
462 |
moving ../b to ../../d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
463 |
moving ../ba to ../../d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
464 |
moving a1 to ../../d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
465 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
466 |
A d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
467 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
468 |
A d3/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
469 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
470 |
A d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
471 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
472 |
A d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
473 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
474 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
475 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
476 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
477 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
478 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
479 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
480 |
$ rm -rf d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
481 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
482 |
skip removed files |
1747
91c56c427171
transitive copy/rename
Robin Farine <robin.farine@terminus.org>
parents:
1634
diff
changeset
|
483 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
484 |
$ hg remove d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
485 |
$ hg rename d1 d3 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
486 |
moving d1/a to d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
487 |
moving d1/ba to d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
488 |
moving d1/d11/a1 to d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
489 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
490 |
A d3/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
491 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
492 |
A d3/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
493 |
d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
494 |
A d3/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
495 |
d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
496 |
R d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
497 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
498 |
R d1/ba |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
499 |
R d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
500 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
501 |
4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
502 |
$ rm -rf d3 |
1822
64df4220b349
copy/rename to a removed destination file
Robin Farine <robin.farine@terminus.org>
parents:
1747
diff
changeset
|
503 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
504 |
transitive rename |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
505 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
506 |
$ hg rename d1/b d1/bb |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
507 |
$ hg rename d1/bb d1/bc |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
508 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
509 |
A d1/bc |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
510 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
511 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
512 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
513 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
514 |
$ rm d1/bc |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
515 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
516 |
transitive rename --after |
10466
d1f209bb9564
patch: separate reverse copy data (issue1959)
Wagner Bruna <wbruna@softwareexpress.com.br>
parents:
8518
diff
changeset
|
517 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
518 |
$ hg rename d1/b d1/bb |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
519 |
$ mv d1/bb d1/bc |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
520 |
$ hg rename --after d1/bb d1/bc |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
521 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
522 |
A d1/bc |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
523 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
524 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
525 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
526 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
527 |
$ rm d1/bc |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
528 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
529 |
$ echo "# idempotent renames (d1/b -> d1/bb followed by d1/bb -> d1/b)" |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
530 |
# idempotent renames (d1/b -> d1/bb followed by d1/bb -> d1/b) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
531 |
$ hg rename d1/b d1/bb |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
532 |
$ echo "some stuff added to d1/bb" >> d1/bb |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
533 |
$ hg rename d1/bb d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
534 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
535 |
M d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
536 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
537 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
538 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
539 |
overwriting with renames (issue1959) |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
540 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
541 |
$ hg rename d1/a d1/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
542 |
$ hg rename d1/b d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
543 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
544 |
A d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
545 |
d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
546 |
A d1/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
547 |
d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
548 |
R d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
549 |
$ hg diff --git |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
550 |
diff --git a/d1/b b/d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
551 |
rename from d1/b |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
552 |
rename to d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
553 |
diff --git a/d1/a b/d1/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
554 |
copy from d1/a |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
555 |
copy to d1/c |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
556 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
557 |
2 files updated, 0 files merged, 1 files removed, 0 files unresolved |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
558 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
559 |
check illegal path components |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
560 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
561 |
$ hg rename d1/d11/a1 .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
562 |
abort: path contains illegal component: .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
563 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
564 |
$ hg rename d1/d11/a1 ../foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
565 |
abort: ../foo not under root |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
566 |
$ hg status -C |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
567 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
568 |
$ mv d1/d11/a1 .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
569 |
$ hg rename --after d1/d11/a1 .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
570 |
abort: path contains illegal component: .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
571 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
572 |
! d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
573 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
574 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
575 |
$ rm .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
576 |
|
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
577 |
$ hg rename d1/d11/a1 .hg |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
578 |
abort: path contains illegal component: .hg/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
579 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
580 |
$ hg rename d1/d11/a1 .. |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
581 |
abort: ../a1 not under root |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
582 |
$ hg status -C |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
583 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
584 |
$ mv d1/d11/a1 .hg |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
585 |
$ hg rename --after d1/d11/a1 .hg |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
586 |
abort: path contains illegal component: .hg/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
587 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
588 |
! d1/d11/a1 |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
589 |
$ hg update -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
590 |
1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
591 |
$ rm .hg/a1 |
1976
df8416346bb7
Enable path validation for copy, rename, debugwalk and other canonpath users.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1933
diff
changeset
|
592 |
|
12098
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
593 |
$ (cd d1/d11; hg rename ../../d2/b ../../.hg/foo) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
594 |
abort: path contains illegal component: .hg/foo |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
595 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
596 |
$ (cd d1/d11; hg rename ../../d2/b ../../../foo) |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
597 |
abort: ../../../foo not under root |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
598 |
$ hg status -C |
12108d7f2ce1
tests: unify test-rename
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11551
diff
changeset
|
599 |