Mercurial > evolve
annotate tests/test-stack-branch.t @ 2669:b933a8068c17
topic: add some initial support for using stack on named branch
Stack is a useful command that can make sense in other context. The current
support is hacky and awful, but we have something!
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 28 Jun 2017 02:45:57 +0200 |
parents | |
children | f5d52fa1cd55 |
rev | line source |
---|---|
2669
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
1 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
2 $ . "$TESTDIR/testlib/topic_setup.sh" |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
3 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
4 Initial setup |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
5 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
6 $ cat << EOF >> $HGRCPATH |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
7 > [ui] |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
8 > logtemplate = {rev} {branch} \{{get(namespaces, "topics")}} {phase} {desc|firstline}\n |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
9 > [experimental] |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
10 > evolution=createmarkers,exchange,allowunstable |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
11 > EOF |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
12 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
13 $ hg init main |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
14 $ cd main |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
15 $ hg branch other |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
16 marked working directory as branch other |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
17 (branches are permanent and global, did you want a bookmark?) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
18 $ echo aaa > aaa |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
19 $ hg add aaa |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
20 $ hg commit -m c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
21 $ echo aaa > bbb |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
22 $ hg add bbb |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
23 $ hg commit -m c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
24 $ hg branch foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
25 marked working directory as branch foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
26 $ echo aaa > ccc |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
27 $ hg add ccc |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
28 $ hg commit -m c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
29 $ echo aaa > ddd |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
30 $ hg add ddd |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
31 $ hg commit -m c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
32 $ echo aaa > eee |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
33 $ hg add eee |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
34 $ hg commit -m c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
35 $ echo aaa > fff |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
36 $ hg add fff |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
37 $ hg commit -m c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
38 $ hg log -G |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
39 @ 5 foo {} draft c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
40 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
41 o 4 foo {} draft c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
42 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
43 o 3 foo {} draft c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
44 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
45 o 2 foo {} draft c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
46 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
47 o 1 other {} draft c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
48 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
49 o 0 other {} draft c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
50 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
51 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
52 Check that topic without any parent does not crash --list |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
53 --------------------------------------------------------- |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
54 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
55 $ hg up other |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
56 0 files updated, 0 files merged, 4 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
57 $ hg stack |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
58 ### topic: None |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
59 ### branch: other |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
60 b2@ c_b (current) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
61 b1: c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
62 $ hg phase --public 'branch("other")' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
63 $ hg up foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
64 4 files updated, 0 files merged, 0 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
65 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
66 Simple test |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
67 ----------- |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
68 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
69 'hg stack' list all changeset in the topic |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
70 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
71 $ hg branch |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
72 foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
73 $ hg stack |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
74 ### topic: None |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
75 ### branch: foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
76 b4@ c_f (current) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
77 b3: c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
78 b2: c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
79 b1: c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
80 ^ c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
81 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
82 Test "t#" reference |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
83 ------------------- |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
84 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
85 $ hg up b2 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
86 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
87 $ hg up foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
88 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
89 $ hg up b42 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
90 abort: cannot resolve "b42": branch "foo" has only 4 changesets |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
91 [255] |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
92 $ hg up b2 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
93 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
94 $ hg summary |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
95 parent: 3:f61adbacd17a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
96 c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
97 branch: foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
98 commit: (clean) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
99 update: 2 new changesets (update) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
100 phases: 4 draft |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
101 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
102 Case with some of the branch unstable |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
103 ------------------------------------ |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
104 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
105 $ echo bbb > ddd |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
106 $ hg commit --amend |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
107 $ hg log -G |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
108 @ 7 foo {} draft c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
109 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
110 | o 5 foo {} draft c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
111 | | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
112 | o 4 foo {} draft c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
113 | | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
114 | x 3 foo {} draft c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
115 |/ |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
116 o 2 foo {} draft c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
117 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
118 o 1 other {} public c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
119 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
120 o 0 other {} public c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
121 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
122 $ hg stack |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
123 ### topic: None |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
124 ### branch: foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
125 b4$ c_f (unstable) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
126 b3$ c_e (unstable) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
127 b2@ c_d (current) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
128 b1: c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
129 ^ c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
130 $ hg up b3 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
131 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
132 $ hg stack |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
133 ### topic: None |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
134 ### branch: foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
135 b4$ c_f (unstable) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
136 b3$ c_e (current unstable) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
137 b2: c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
138 b1: c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
139 ^ c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
140 $ hg up b2 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
141 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
142 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
143 Also test the revset: |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
144 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
145 $ hg log -r 'stack()' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
146 abort: no active topic to list |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
147 [255] |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
148 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
149 Case with multiple heads on the topic |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
150 ------------------------------------- |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
151 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
152 Make things linear again |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
153 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
154 $ hg rebase -s 'desc(c_e)' -d 'desc(c_d) - obsolete()' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
155 rebasing 4:4f2a69f6d380 "c_e" |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
156 rebasing 5:913c298d8b0a "c_f" |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
157 $ hg log -G |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
158 o 9 foo {} draft c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
159 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
160 o 8 foo {} draft c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
161 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
162 @ 7 foo {} draft c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
163 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
164 o 2 foo {} draft c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
165 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
166 o 1 other {} public c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
167 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
168 o 0 other {} public c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
169 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
170 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
171 Create the second branch |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
172 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
173 $ hg up 'desc(c_d)' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
174 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
175 $ echo aaa > ggg |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
176 $ hg add ggg |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
177 $ hg commit -m c_g |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
178 created new head |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
179 $ echo aaa > hhh |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
180 $ hg add hhh |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
181 $ hg commit -m c_h |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
182 $ hg log -G |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
183 @ 11 foo {} draft c_h |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
184 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
185 o 10 foo {} draft c_g |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
186 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
187 | o 9 foo {} draft c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
188 | | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
189 | o 8 foo {} draft c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
190 |/ |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
191 o 7 foo {} draft c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
192 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
193 o 2 foo {} draft c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
194 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
195 o 1 other {} public c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
196 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
197 o 0 other {} public c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
198 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
199 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
200 Test output |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
201 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
202 $ hg stack |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
203 ### topic: None (2 heads) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
204 ### branch: foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
205 b6: c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
206 b5: c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
207 b2^ c_d (base) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
208 b4@ c_h (current) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
209 b3: c_g |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
210 b2: c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
211 b1: c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
212 ^ c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
213 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
214 Case with multiple heads on the topic with unstability involved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
215 --------------------------------------------------------------- |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
216 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
217 We amend the message to make sure the display base pick the right changeset |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
218 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
219 $ hg up 'desc(c_d)' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
220 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
221 $ echo ccc > ddd |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
222 $ hg commit --amend -m 'c_D' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
223 $ hg rebase -d . -s 'desc(c_g)' |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
224 rebasing 10:2ebb6e48ab8a "c_g" |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
225 rebasing 11:634f38e27a1d "c_h" |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
226 $ hg log -G |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
227 o 15 foo {} draft c_h |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
228 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
229 o 14 foo {} draft c_g |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
230 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
231 @ 13 foo {} draft c_D |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
232 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
233 | o 9 foo {} draft c_f |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
234 | | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
235 | o 8 foo {} draft c_e |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
236 | | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
237 | x 7 foo {} draft c_d |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
238 |/ |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
239 o 2 foo {} draft c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
240 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
241 o 1 other {} public c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
242 | |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
243 o 0 other {} public c_a |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
244 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
245 |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
246 $ hg stack |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
247 ### topic: None (2 heads) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
248 ### branch: foo |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
249 b6$ c_f (unstable) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
250 b5$ c_e (unstable) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
251 b2^ c_D (base) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
252 b4: c_h |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
253 b3: c_g |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
254 b2@ c_D (current) |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
255 b1: c_c |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
256 ^ c_b |
b933a8068c17
topic: add some initial support for using stack on named branch
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
257 |