annotate tests/test-rebase-base.t @ 31493:06d3c40fc3e7

graphlog: pass function arguments without expansion It's annoying on Python 3 because keys must be unicode type. Let's stop using **opts expansion when not necessary.
author Yuya Nishihara <yuya@tcha.org>
date Tue, 14 Mar 2017 18:16:13 +0900
parents 51e7c83e05ee
children 13dc00c233b7
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
30585
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
1 $ cat >> $HGRCPATH <<EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
2 > [extensions]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
3 > rebase=
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
4 > drawdag=$TESTDIR/drawdag.py
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
5 >
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
6 > [phases]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
7 > publish=False
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
8 >
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
9 > [alias]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
10 > tglog = log -G --template "{rev}: {desc}"
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
11 > EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
12
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
13 $ rebasewithdag() {
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
14 > N=`$PYTHON -c "print($N+1)"`
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
15 > hg init repo$N && cd repo$N
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
16 > hg debugdrawdag
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
17 > hg rebase "$@" > _rebasetmp
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
18 > r=$?
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
19 > grep -v 'saved backup bundle' _rebasetmp
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
20 > [ $r -eq 0 ] && hg tglog
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
21 > cd ..
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
22 > return $r
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
23 > }
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
24
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
25 Single branching point, without merge:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
26
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
27 $ rebasewithdag -b D -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
28 > D E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
29 > |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
30 > Z B C # C: branching point, E should be picked
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
31 > \|/ # B should not be picked
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
32 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
33 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
34 > R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
35 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
36 rebasing 3:d6003a550c2c "C" (C)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
37 rebasing 5:4526cf523425 "D" (D)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
38 rebasing 6:b296604d9846 "E" (E tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
39 o 6: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
40 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
41 | o 5: D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
42 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
43 o 4: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
44 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
45 o 3: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
46 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
47 | o 2: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
48 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
49 o 1: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
50 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
51 o 0: R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
52
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
53 Multiple branching points caused by selecting a single merge changeset:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
54
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
55 $ rebasewithdag -b E -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
56 > E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
57 > /|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
58 > B C D # B, C: multiple branching points
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
59 > | |/ # D should not be picked
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
60 > Z | /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
61 > \|/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
62 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
63 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
64 > R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
65 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
66 rebasing 2:c1e6b162678d "B" (B)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
67 rebasing 3:d6003a550c2c "C" (C)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
68 rebasing 6:5251e0cb7302 "E" (E tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
69 o 6: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
70 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
71 | o 5: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
72 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
73 o | 4: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
74 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
75 o 3: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
76 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
77 | o 2: D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
78 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
79 o 1: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
80 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
81 o 0: R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
82
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
83 Rebase should not extend the "--base" revset using "descendants":
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
84
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
85 $ rebasewithdag -b B -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
86 > E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
87 > /|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
88 > Z B C # descendants(B) = B+E. With E, C will be included incorrectly
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
89 > \|/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
90 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
91 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
92 > R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
93 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
94 rebasing 2:c1e6b162678d "B" (B)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
95 rebasing 5:5251e0cb7302 "E" (E tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
96 o 5: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
97 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
98 | o 4: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
99 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
100 | o 3: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
101 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
102 o | 2: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
103 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
104 o 1: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
105 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
106 o 0: R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
107
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
108 Rebase should not simplify the "--base" revset using "roots":
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
109
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
110 $ rebasewithdag -b B+E -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
111 > E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
112 > /|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
113 > Z B C # roots(B+E) = B. Without E, C will be missed incorrectly
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
114 > \|/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
115 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
116 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
117 > R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
118 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
119 rebasing 2:c1e6b162678d "B" (B)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
120 rebasing 3:d6003a550c2c "C" (C)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
121 rebasing 5:5251e0cb7302 "E" (E tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
122 o 5: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
123 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
124 | o 4: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
125 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
126 o | 3: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
127 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
128 o 2: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
129 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
130 o 1: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
131 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
132 o 0: R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
133
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
134 The destination is one of the two branching points of a merge:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
135
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
136 $ rebasewithdag -b F -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
137 > F
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
138 > / \
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
139 > E D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
140 > / /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
141 > Z C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
142 > \ /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
143 > B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
144 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
145 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
146 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
147 nothing to rebase
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
148 [1]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
149
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
150 Multiple branching points caused by multiple bases (issue5420):
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
151
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
152 $ rebasewithdag -b E1+E2+C2+B1 -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
153 > Z E2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
154 > | /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
155 > F E1 C2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
156 > |/ /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
157 > E C1 B2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
158 > |/ /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
159 > C B1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
160 > |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
161 > B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
162 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
163 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
164 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
165 > R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
166 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
167 rebasing 3:a113dbaa660a "B1" (B1)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
168 rebasing 5:06ce7b1cc8c2 "B2" (B2)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
169 rebasing 6:0ac98cce32d3 "C1" (C1)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
170 rebasing 8:781512f5e33d "C2" (C2)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
171 rebasing 9:428d8c18f641 "E1" (E1)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
172 rebasing 11:e1bf82f6b6df "E2" (E2)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
173 o 12: E2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
174 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
175 o 11: E1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
176 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
177 | o 10: C2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
178 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
179 | o 9: C1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
180 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
181 | o 8: B2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
182 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
183 | o 7: B1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
184 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
185 o 6: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
186 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
187 o 5: F
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
188 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
189 o 4: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
190 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
191 o 3: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
192 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
193 o 2: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
194 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
195 o 1: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
196 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
197 o 0: R
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
198
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
199 Multiple branching points with multiple merges:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
200
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
201 $ rebasewithdag -b G+P -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
202 > G H P
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
203 > |\ /| |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
204 > F E D M N
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
205 > \|/| /| |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
206 > Z C B I J K L
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
207 > \|/ |/ |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
208 > A A A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
209 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
210 rebasing 2:dc0947a82db8 "C" (C)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
211 rebasing 8:215e7b0814e1 "D" (D)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
212 rebasing 9:03ca77807e91 "E" (E)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
213 rebasing 10:afc707c82df0 "F" (F)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
214 rebasing 13:018caa673317 "G" (G)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
215 rebasing 14:4f710fbd68cb "H" (H)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
216 rebasing 3:08ebfeb61bac "I" (I)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
217 rebasing 4:a0a5005cec67 "J" (J)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
218 rebasing 5:83780307a7e8 "K" (K)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
219 rebasing 6:e131637a1cb6 "L" (L)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
220 rebasing 11:d6fe3d11d95d "M" (M)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
221 rebasing 12:fa1e02269063 "N" (N)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
222 rebasing 15:448b1a498430 "P" (P tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
223 o 15: P
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
224 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
225 | o 14: N
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
226 | |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
227 o \ \ 13: M
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
228 |\ \ \
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
229 | | | o 12: L
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
230 | | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
231 | | o | 11: K
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
232 | | |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
233 | o / 10: J
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
234 | |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
235 o / 9: I
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
236 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
237 | o 8: H
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
238 | |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
239 | | | o 7: G
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
240 | | |/|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
241 | | | o 6: F
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
242 | | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
243 | | o | 5: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
244 | | |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
245 | o | 4: D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
246 | |\|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
247 +---o 3: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
248 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
249 o | 2: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
250 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
251 | o 1: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
252 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
253 o 0: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
254
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
255 Slightly more complex merge case (mentioned in https://www.mercurial-scm.org/pipermail/mercurial-devel/2016-November/091074.html):
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
256
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
257 $ rebasewithdag -b A3+B3 -d Z <<'EOF'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
258 > Z C1 A3 B3
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
259 > | / / \ / \
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
260 > M3 C0 A1 A2 B1 B2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
261 > | / | | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
262 > M2 M1 C1 C1 M3
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
263 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
264 > M1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
265 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
266 > M0
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
267 > EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
268 rebasing 4:8817fae53c94 "C0" (C0)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
269 rebasing 6:06ca5dfe3b5b "B2" (B2)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
270 rebasing 7:73508237b032 "C1" (C1)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
271 rebasing 9:fdb955e2faed "A2" (A2)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
272 rebasing 11:1b2f368c3cb5 "A3" (A3)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
273 rebasing 10:0a33b0519128 "B1" (B1)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
274 rebasing 12:bd6a37b5b67a "B3" (B3 tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
275 o 12: B3
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
276 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
277 | o 11: B1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
278 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
279 | | o 10: A3
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
280 | | |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
281 | +---o 9: A2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
282 | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
283 | o | 8: C1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
284 | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
285 o | | 7: B2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
286 | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
287 | o | 6: C0
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
288 |/ /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
289 o | 5: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
290 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
291 o | 4: M3
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
292 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
293 o | 3: M2
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
294 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
295 | o 2: A1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
296 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
297 o 1: M1
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
298 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
299 o 0: M0
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
300
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
301 Mixed rebasable and non-rebasable bases (unresolved, issue5422):
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
302
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
303 $ rebasewithdag -b C+D -d B <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
304 > D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
305 > /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
306 > B C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
307 > |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
308 > A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
309 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
310 nothing to rebase
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
311 [1]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
312
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
313 Disconnected graph:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
314
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
315 $ rebasewithdag -b B -d Z <<'EOS'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
316 > B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
317 > |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
318 > Z A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
319 > EOS
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
320 nothing to rebase from 112478962961 to 48b9aae0607f
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
321 [1]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
322
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
323 Multiple roots. Roots are ancestors of dest:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
324
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
325 $ rebasewithdag -b B+D -d Z <<'EOF'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
326 > D Z B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
327 > \|\|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
328 > C A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
329 > EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
330 rebasing 2:112478962961 "B" (B)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
331 rebasing 3:b70f76719894 "D" (D)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
332 o 4: D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
333 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
334 | o 3: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
335 |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
336 o 2: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
337 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
338 | o 1: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
339 |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
340 o 0: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
341
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
342 Multiple roots. One root is not an ancestor of dest:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
343
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
344 $ rebasewithdag -b B+D -d Z <<'EOF'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
345 > Z B D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
346 > \|\|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
347 > A C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
348 > EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
349 nothing to rebase from 86d01f49c0d9+b70f76719894 to 262e37e34f63
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
350 [1]
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
351
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
352 Multiple roots. One root is not an ancestor of dest. Select using a merge:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
353
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
354 $ rebasewithdag -b E -d Z <<'EOF'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
355 > E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
356 > |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
357 > Z B D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
358 > \|\|
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
359 > A C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
360 > EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
361 rebasing 2:86d01f49c0d9 "B" (B)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
362 rebasing 5:539a0ff83ea9 "E" (E tip)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
363 o 5: E
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
364 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
365 | o 4: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
366 | |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
367 | | o 3: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
368 | | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
369 o | | 2: D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
370 |/ /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
371 o / 1: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
372 /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
373 o 0: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
374
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
375 Multiple roots. Two children share two parents while dest has only one parent:
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
376
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
377 $ rebasewithdag -b B+D -d Z <<'EOF'
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
378 > Z B D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
379 > \|\|\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
380 > A C A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
381 > EOF
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
382 rebasing 2:86d01f49c0d9 "B" (B)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
383 rebasing 3:b7df2ca01aa8 "D" (D)
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
384 o 4: D
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
385 |\
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
386 +---o 3: B
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
387 | |/
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
388 | o 2: Z
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
389 | |
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
390 o | 1: C
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
391 /
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
392 o 0: A
51e7c83e05ee rebase: calculate ancestors for --base separately (issue5420)
Jun Wu <quark@fb.com>
parents:
diff changeset
393