annotate tests/test-rebase-rename.t @ 18657:d4a79e075303 stable

debugobsolete: improve command help The behavior without argument was not documented.
author Pierre-Yves David <pierre-yves.david@ens-lyon.org>
date Sat, 09 Feb 2013 23:28:42 +0000
parents f23dea2b296e
children 5b7175377bab
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
1 $ cat >> $HGRCPATH <<EOF
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
2 > [extensions]
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
3 > graphlog=
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
4 > rebase=
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
5 >
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
6 > [alias]
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
7 > tlog = log --template "{rev}: '{desc}' {branches}\n"
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
8 > tglog = tlog --graph
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
9 > EOF
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
10
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
11
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
12 $ hg init a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
13 $ cd a
11198
b345b1cc124f rebase: use helpers.sh in tests
Matt Mackall <mpm@selenic.com>
parents: 7954
diff changeset
14
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
15 $ echo a > a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
16 $ hg ci -Am A
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
17 adding a
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
18
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
19 $ echo b > b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
20 $ hg ci -Am B
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
21 adding b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
22
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
23 $ hg mv b b-renamed
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
24 $ hg ci -m 'rename B'
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
25
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
26 $ hg up -q -C 1
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
27
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
28 $ hg mv a a-renamed
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
29
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
30 $ hg ci -m 'rename A'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
31 created new head
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
32
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
33 $ hg tglog
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
34 @ 3: 'rename A'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
35 |
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
36 | o 2: 'rename B'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
37 |/
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
38 o 1: 'B'
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
39 |
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
40 o 0: 'A'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
41
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
42
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
43 Rename is tracked:
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
44
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
45 $ hg tlog -p --git -r tip
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
46 3: 'rename A'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
47 diff --git a/a b/a-renamed
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
48 rename from a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
49 rename to a-renamed
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
50
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
51 Rebase the revision containing the rename:
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
52
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
53 $ hg rebase -s 3 -d 2
12640
6cc4b14fb76b tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents: 12608
diff changeset
54 saved backup bundle to $TESTTMP/a/.hg/strip-backup/*-backup.hg (glob)
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
55
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
56 $ hg tglog
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
57 @ 3: 'rename A'
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
58 |
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
59 o 2: 'rename B'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
60 |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
61 o 1: 'B'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
62 |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
63 o 0: 'A'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
64
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
65
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
66 Rename is not lost:
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
67
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
68 $ hg tlog -p --git -r tip
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
69 3: 'rename A'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
70 diff --git a/a b/a-renamed
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
71 rename from a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
72 rename to a-renamed
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
73
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
74
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
75 Rebased revision does not contain information about b (issue3739)
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
76
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
77 $ hg log -r 3 --debug
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
78 changeset: 3:3b905b1064f14ace3ad02353b79dd42d32981655
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
79 tag: tip
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
80 phase: draft
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
81 parent: 2:920a371a5635af23a26a011ca346cecd1cfcb942
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
82 parent: -1:0000000000000000000000000000000000000000
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
83 manifest: 3:c4a62b2b64593c8fe0523d4c1ba2e243a8bd4dce
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
84 user: test
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
85 date: Thu Jan 01 00:00:00 1970 +0000
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
86 files+: a-renamed
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
87 files-: a
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
88 extra: branch=default
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
89 extra: rebase_source=89af05cb38a281f891c6f5581dd027092da29166
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
90 description:
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
91 rename A
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
92
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
93
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
94
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
95 $ cd ..
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
96
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
97
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
98 $ hg init b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
99 $ cd b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
100
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
101 $ echo a > a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
102 $ hg ci -Am A
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
103 adding a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
104
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
105 $ echo b > b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
106 $ hg ci -Am B
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
107 adding b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
108
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
109 $ hg cp b b-copied
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
110 $ hg ci -Am 'copy B'
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
111
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
112 $ hg up -q -C 1
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
113
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
114 $ hg cp a a-copied
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
115 $ hg ci -m 'copy A'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
116 created new head
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
117
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
118 $ hg tglog
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
119 @ 3: 'copy A'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
120 |
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
121 | o 2: 'copy B'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
122 |/
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
123 o 1: 'B'
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
124 |
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
125 o 0: 'A'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
126
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
127 Copy is tracked:
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
128
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
129 $ hg tlog -p --git -r tip
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
130 3: 'copy A'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
131 diff --git a/a b/a-copied
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
132 copy from a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
133 copy to a-copied
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
134
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
135 Rebase the revision containing the copy:
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
136
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
137 $ hg rebase -s 3 -d 2
12640
6cc4b14fb76b tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents: 12608
diff changeset
138 saved backup bundle to $TESTTMP/b/.hg/strip-backup/*-backup.hg (glob)
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
139
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
140 $ hg tglog
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
141 @ 3: 'copy A'
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
142 |
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
143 o 2: 'copy B'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
144 |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
145 o 1: 'B'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
146 |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
147 o 0: 'A'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
148
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
149
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
150 Copy is not lost:
7954
b969611064ae rebase: don't lose rename/copy data (Issue1423)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
151
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
152 $ hg tlog -p --git -r tip
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
153 3: 'copy A'
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
154 diff --git a/a b/a-copied
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
155 copy from a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
156 copy to a-copied
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
157
18136
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
158
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
159 Rebased revision does not contain information about b (issue3739)
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
160
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
161 $ hg log -r 3 --debug
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
162 changeset: 3:98f6e6dbf45ab54079c2237fbd11066a5c41a11d
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
163 tag: tip
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
164 phase: draft
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
165 parent: 2:39e588434882ff77d01229d169cdc77f29e8855e
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
166 parent: -1:0000000000000000000000000000000000000000
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
167 manifest: 3:2232f329d66fffe3930d43479ae624f66322b04d
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
168 user: test
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
169 date: Thu Jan 01 00:00:00 1970 +0000
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
170 files+: a-copied
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
171 extra: branch=default
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
172 extra: rebase_source=0a8162ff18a8900df8df8ef7ac0046955205613e
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
173 description:
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
174 copy A
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
175
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
176
f23dea2b296e copies: do not track backward copies, only renames (issue3739)
Siddharth Agarwal <sid0@fb.com>
parents: 16913
diff changeset
177
13778
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
178 $ cd ..
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
179
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
180
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
181 Test rebase across repeating renames:
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
182
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
183 $ hg init repo
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
184
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
185 $ cd repo
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
186
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
187 $ echo testing > file1.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
188 $ hg add file1.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
189 $ hg ci -m "Adding file1"
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
190
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
191 $ hg rename file1.txt file2.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
192 $ hg ci -m "Rename file1 to file2"
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
193
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
194 $ echo Unrelated change > unrelated.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
195 $ hg add unrelated.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
196 $ hg ci -m "Unrelated change"
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
197
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
198 $ hg rename file2.txt file1.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
199 $ hg ci -m "Rename file2 back to file1"
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
200
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
201 $ hg update -r -2
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
202 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
203
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
204 $ echo Another unrelated change >> unrelated.txt
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
205 $ hg ci -m "Another unrelated change"
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
206 created new head
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
207
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
208 $ hg tglog
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
209 @ 4: 'Another unrelated change'
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
210 |
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
211 | o 3: 'Rename file2 back to file1'
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
212 |/
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
213 o 2: 'Unrelated change'
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
214 |
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
215 o 1: 'Rename file1 to file2'
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
216 |
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
217 o 0: 'Adding file1'
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
218
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
219
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
220 $ hg rebase -s 4 -d 3
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
221 saved backup bundle to $TESTTMP/repo/.hg/strip-backup/*-backup.hg (glob)
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
222
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
223 $ hg diff --stat -c .
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
224 unrelated.txt | 1 +
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
225 1 files changed, 1 insertions(+), 0 deletions(-)
46c3043253fb rebase: don't mark file as removed if missing in parent's manifest (issue2725)
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents: 12640
diff changeset
226
16913
f2719b387380 tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents: 13778
diff changeset
227 $ cd ..