Mercurial > evolve
annotate tests/test-topic-tutorial.t @ 2718:b6fa7b3e13d4
topics: add a config knob to forbid untopiced commit
After this patch one can add the following to their hgrc to stop allowing new
commits with no topic on it.
[experimental]
enforce-topic = yes
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Thu, 06 Jul 2017 03:31:11 +0530 |
parents | f19b314d8475 |
children | c64e2167514b |
rev | line source |
---|---|
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
1 ============== |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
2 Topic Tutorial |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
3 ============== |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
4 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
5 .. This test file is also supposed to be able to compile as a rest file. |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
6 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
7 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
8 .. Some Setup:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
9 |
2045
db617700d318
tests: move "test setup" script into a 'testlib' directory
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2014
diff
changeset
|
10 $ . "$TESTDIR/testlib/topic_setup.sh" |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
11 $ hg init server |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
12 $ cd server |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
13 $ cat >> .hg/hgrc << EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
14 > [ui] |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
15 > user= Shopping Master |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
16 > EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
17 $ cat >> shopping << EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
18 > Spam |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
19 > Whizzo butter |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
20 > Albatross |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
21 > Rat (rather a lot) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
22 > Jugged fish |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
23 > Blancmange |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
24 > Salmon mousse |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
25 > EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
26 $ hg commit -A -m "Shopping list" |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
27 adding shopping |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
28 $ cd .. |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
29 $ hg clone server client |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
30 updating to branch default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
31 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
32 $ cd client |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
33 $ cat >> .hg/hgrc << EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
34 > [ui] |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
35 > user= Tutorial User |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
36 > EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
37 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
38 Topic branches are lightweight branches which disappear when changes are |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
39 finalized (move to the public phase). They can help users to organise and share |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
40 their unfinished work. |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
41 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
42 Topic Basics |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
43 ============ |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
44 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
45 Let's says we use Mercurial to manage our shopping list:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
46 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
47 $ hg log --graph |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
48 @ changeset: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
49 tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
50 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
51 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
52 summary: Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
53 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
54 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
55 We are about to do some edition to this list and would like to do them within |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
56 a topic. Creating a new topic is done using the ``topic`` command:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
57 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
58 $ hg topic food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
59 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
60 As for named branch, our topic is active but it does not contains any changesets yet:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
61 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
62 $ hg topic |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
63 * food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
64 $ hg summary |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
65 parent: 0:38da43f0a2ea tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
66 Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
67 branch: default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
68 commit: (clean) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
69 update: (current) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
70 topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
71 $ hg log --graph |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
72 @ changeset: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
73 tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
74 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
75 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
76 summary: Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
77 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
78 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
79 Our next commit will be part of the active topic:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
80 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
81 $ cat >> shopping << EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
82 > Egg |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
83 > Suggar |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
84 > Vinegar |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
85 > Oil |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
86 > EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
87 $ hg commit -m "adding condiments" |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
88 $ hg log --graph --rev 'topic("food")' |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
89 @ changeset: 1:13900241408b |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
90 | tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
91 ~ topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
92 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
93 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
94 summary: adding condiments |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
95 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
96 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
97 And future commit will be part of that topic too:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
98 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
99 $ cat >> shopping << EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
100 > Bananas |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
101 > Pear |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
102 > Apple |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
103 > EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
104 $ hg commit -m "adding fruits" |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
105 $ hg log --graph --rev 'topic("food")' |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
106 @ changeset: 2:287de11b401f |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
107 | tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
108 | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
109 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
110 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
111 | summary: adding fruits |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
112 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
113 o changeset: 1:13900241408b |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
114 | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
115 ~ user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
116 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
117 summary: adding condiments |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
118 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
119 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
120 We can get a compact view of the content of our topic using the ``stack`` command:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
121 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
122 $ hg stack |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
123 ### topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
124 ### branch: default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
125 t2@ adding fruits (current) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
126 t1: adding condiments |
2712
f19b314d8475
topics: add t0 and b0 to the stack
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2679
diff
changeset
|
127 t0^ Shopping list (base) |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
128 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
129 The topic desactivate when we update away from it:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
130 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
131 $ hg up default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
132 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
133 $ hg topic |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
134 food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
135 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
136 Note that ``default`` (name of the branch) now refers to the tipmost changeset of default without a topic:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
137 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
138 $ hg log --graph |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
139 o changeset: 2:287de11b401f |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
140 | tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
141 | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
142 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
143 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
144 | summary: adding fruits |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
145 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
146 o changeset: 1:13900241408b |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
147 | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
148 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
149 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
150 | summary: adding condiments |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
151 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
152 @ changeset: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
153 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
154 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
155 summary: Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
156 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
157 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
158 And updating back to the topic reactivate it:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
159 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
160 $ hg up food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
161 switching to topic food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
162 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
163 $ hg topic |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
164 * food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
165 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
166 The name used for updating does not affect the activation of the topic, updating to a revision part of a topic will activate it in all cases:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
167 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
168 $ hg up default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
169 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
170 $ hg up --rev 'desc("condiments")' |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
171 switching to topic food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
172 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
173 $ hg topic |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
174 * food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
175 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
176 .. server side activity:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
177 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
178 $ cd ../server/ |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
179 $ cat > shopping << EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
180 > T-Shirt |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
181 > Trousers |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
182 > Spam |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
183 > Whizzo butter |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
184 > Albatross |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
185 > Rat (rather a lot) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
186 > Jugged fish |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
187 > Blancmange |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
188 > Salmon mousse |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
189 > EOF |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
190 $ hg commit -A -m "Adding clothes" |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
191 $ cd ../client |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
192 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
193 Topic will also affect rebase and merge destination. Let's pull the latest update from the main server:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
194 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
195 $ hg pull |
2120
e38156312410
tests: add glob for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
2045
diff
changeset
|
196 pulling from $TESTTMP/server (glob) |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
197 searching for changes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
198 adding changesets |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
199 adding manifests |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
200 adding file changes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
201 added 1 changesets with 1 changes to 1 files (+1 heads) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
202 (run 'hg heads' to see heads) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
203 $ hg log -G |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
204 o changeset: 3:6104862e8b84 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
205 | tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
206 | parent: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
207 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
208 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
209 | summary: Adding clothes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
210 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
211 | o changeset: 2:287de11b401f |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
212 | | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
213 | | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
214 | | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
215 | | summary: adding fruits |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
216 | | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
217 | @ changeset: 1:13900241408b |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
218 |/ topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
219 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
220 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
221 | summary: adding condiments |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
222 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
223 o changeset: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
224 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
225 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
226 summary: Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
227 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
228 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
229 The topic head will not be considered when merge from the new head of the branch:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
230 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
231 $ hg up default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
232 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
233 $ hg merge |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
234 abort: branch 'default' has one head - please merge with an explicit rev |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
235 (run 'hg heads' to see all heads) |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
236 [255] |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
237 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
238 But the topic will see that branch head as a valid destination:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
239 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
240 $ hg up food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
241 switching to topic food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
242 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
243 $ hg rebase |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
244 rebasing 1:13900241408b "adding condiments" |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
245 merging shopping |
2679
5156a67f66a6
topics: update current topic to the topic of newly rebased commit (issue5551)
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2120
diff
changeset
|
246 switching to topic food |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
247 rebasing 2:287de11b401f "adding fruits" |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
248 merging shopping |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
249 $ hg log --graph |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
250 @ changeset: 5:2d50db8b5b4c |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
251 | tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
252 | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
253 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
254 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
255 | summary: adding fruits |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
256 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
257 o changeset: 4:4011b46eeb33 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
258 | topic: food |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
259 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
260 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
261 | summary: adding condiments |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
262 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
263 o changeset: 3:6104862e8b84 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
264 | parent: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
265 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
266 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
267 | summary: Adding clothes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
268 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
269 o changeset: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
270 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
271 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
272 summary: Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
273 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
274 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
275 The topic information will fade out when we publish the changesets:: |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
276 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
277 $ hg topic |
2679
5156a67f66a6
topics: update current topic to the topic of newly rebased commit (issue5551)
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2120
diff
changeset
|
278 * food |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
279 $ hg push |
2120
e38156312410
tests: add glob for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
2045
diff
changeset
|
280 pushing to $TESTTMP/server (glob) |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
281 searching for changes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
282 adding changesets |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
283 adding manifests |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
284 adding file changes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
285 added 2 changesets with 2 changes to 1 files |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
286 2 new obsolescence markers |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
287 $ hg topic |
2679
5156a67f66a6
topics: update current topic to the topic of newly rebased commit (issue5551)
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2120
diff
changeset
|
288 * food |
2013
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
289 $ hg log --graph |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
290 @ changeset: 5:2d50db8b5b4c |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
291 | tag: tip |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
292 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
293 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
294 | summary: adding fruits |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
295 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
296 o changeset: 4:4011b46eeb33 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
297 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
298 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
299 | summary: adding condiments |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
300 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
301 o changeset: 3:6104862e8b84 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
302 | parent: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
303 | user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
304 | date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
305 | summary: Adding clothes |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
306 | |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
307 o changeset: 0:38da43f0a2ea |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
308 user: test |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
309 date: Thu Jan 01 00:00:00 1970 +0000 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
310 summary: Shopping list |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
311 |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
312 $ hg up default |
2e8e4619a240
tutorial: add a first version of the tutorial with the basics
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
313 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
314 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
315 Working with Multiple Topics |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
316 ============================ |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
317 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
318 In the above example, topic are not bring much benefit since you only have one |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
319 line of developement. Topic start to be more useful when you have to work on |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
320 multiple features are the same time. |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
321 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
322 We might go shopping in a hardware store in the same go, so let's add some |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
323 tools to the shopping list withing a new topic:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
324 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
325 $ hg topic tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
326 $ echo hammer >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
327 $ hg ci -m 'Adding hammer' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
328 $ echo saw >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
329 $ hg ci -m 'Adding saw' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
330 $ echo drill >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
331 $ hg ci -m 'Adding drill' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
332 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
333 But are not sure to actually go in the hardward store, so in the meantime, we |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
334 want to extend the list with drinks. We go back to the official default branch |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
335 and start a new topic:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
336 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
337 $ hg up default |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
338 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
339 $ hg topic drinks |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
340 $ echo 'apple juice' >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
341 $ hg ci -m 'Adding apple juice' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
342 $ echo 'orange juice' >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
343 $ hg ci -m 'Adding orange juice' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
344 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
345 We now have two topics:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
346 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
347 $ hg topic |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
348 * drinks |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
349 tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
350 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
351 The information ``hg stack`` command adapt to the active topic:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
352 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
353 $ hg stack |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
354 ### topic: drinks |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
355 ### branch: default |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
356 t2@ Adding orange juice (current) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
357 t1: Adding apple juice |
2712
f19b314d8475
topics: add t0 and b0 to the stack
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2679
diff
changeset
|
358 t0^ adding fruits (base) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
359 $ hg up tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
360 switching to topic tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
361 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
362 $ hg stack |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
363 ### topic: tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
364 ### branch: default |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
365 t3@ Adding drill (current) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
366 t2: Adding saw |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
367 t1: Adding hammer |
2712
f19b314d8475
topics: add t0 and b0 to the stack
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2679
diff
changeset
|
368 t0^ adding fruits (base) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
369 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
370 They are seen as independant branch by Mercurial. No rebase or merge betwen them will be attempted by default:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
371 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
372 $ hg rebase |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
373 nothing to rebase |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
374 [1] |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
375 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
376 .. server activity:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
377 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
378 $ cd ../server |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
379 $ hg up |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
380 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
381 $ mv shopping foo |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
382 $ echo 'Coat' > shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
383 $ cat foo >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
384 $ hg ci -m 'add a coat' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
385 $ echo 'Coat' > shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
386 $ echo 'Shoes' >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
387 $ cat foo >> shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
388 $ hg rm foo |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
389 not removing foo: file is untracked |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
390 [1] |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
391 $ hg ci -m 'add a pair of shoes' |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
392 $ cd ../client |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
393 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
394 Lets see what other people did in the mean time:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
395 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
396 $ hg pull |
2120
e38156312410
tests: add glob for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
2045
diff
changeset
|
397 pulling from $TESTTMP/server (glob) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
398 searching for changes |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
399 adding changesets |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
400 adding manifests |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
401 adding file changes |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
402 added 2 changesets with 2 changes to 1 files (+1 heads) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
403 (run 'hg heads' to see heads) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
404 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
405 There is new changes! We can simply use ``hg rebase`` to update our changeset on top of the latest:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
406 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
407 $ hg rebase |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
408 rebasing 6:183984ef46d1 "Adding hammer" |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
409 merging shopping |
2679
5156a67f66a6
topics: update current topic to the topic of newly rebased commit (issue5551)
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2120
diff
changeset
|
410 switching to topic tools |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
411 rebasing 7:cffff85af537 "Adding saw" |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
412 merging shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
413 rebasing 8:34255b455dac "Adding drill" |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
414 merging shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
415 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
416 But what about the other topic? You can use 'hg topic --verbose' to see information about them:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
417 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
418 $ hg topic --verbose |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
419 drinks (on branch: default, 2 changesets, 2 behind) |
2679
5156a67f66a6
topics: update current topic to the topic of newly rebased commit (issue5551)
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2120
diff
changeset
|
420 * tools (on branch: default, 3 changesets) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
421 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
422 The "2 behind" is telling you that there is 2 new changesets on the named branch of the topic. You need to merge or rebase to incorporate them. |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
423 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
424 Pushing that topic would create a new heads will be prevented:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
425 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
426 $ hg push --rev drinks |
2120
e38156312410
tests: add glob for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
2045
diff
changeset
|
427 pushing to $TESTTMP/server (glob) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
428 searching for changes |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
429 abort: push creates new remote head 70dfa201ed73! |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
430 (merge or see 'hg help push' for details about pushing new heads) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
431 [255] |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
432 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
433 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
434 Even after a rebase Pushing all active topics at the same time will complains about the multiple heads it would create on that branch:: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
435 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
436 $ hg rebase -b drinks |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
437 rebasing 9:8dfa45bd5e0c "Adding apple juice" |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
438 merging shopping |
2679
5156a67f66a6
topics: update current topic to the topic of newly rebased commit (issue5551)
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2120
diff
changeset
|
439 switching to topic drinks |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
440 rebasing 10:70dfa201ed73 "Adding orange juice" |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
441 merging shopping |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
442 switching to topic tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
443 $ hg push |
2120
e38156312410
tests: add glob for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
2045
diff
changeset
|
444 pushing to $TESTTMP/server (glob) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
445 searching for changes |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
446 abort: push creates new remote head 4cd7c1591a67! |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
447 (merge or see 'hg help push' for details about pushing new heads) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
448 [255] |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
449 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
450 Publishing only one of them is allowed (as long as it does not create a new branch head has we just saw in the previous case):: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
451 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
452 $ hg push -r drinks |
2120
e38156312410
tests: add glob for Windows
Matt Harbison <matt_harbison@yahoo.com>
parents:
2045
diff
changeset
|
453 pushing to $TESTTMP/server (glob) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
454 searching for changes |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
455 adding changesets |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
456 adding manifests |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
457 adding file changes |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
458 added 2 changesets with 2 changes to 1 files |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
459 2 new obsolescence markers |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
460 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
461 The publishing topic has now vanished, and the one still draft is now marked as "behind":: |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
462 |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
463 $ hg topic --verbose |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
464 * tools (on branch: default, 3 changesets, 2 behind) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
465 $ hg stack |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
466 ### topic: tools |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
467 ### branch: default, 2 behind |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
468 t3@ Adding drill (current) |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
469 t2: Adding saw |
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
470 t1: Adding hammer |
2712
f19b314d8475
topics: add t0 and b0 to the stack
Pulkit Goyal <7895pulkit@gmail.com>
parents:
2679
diff
changeset
|
471 t0^ add a pair of shoes (base) |
2014
cd6d32a0155c
tutorial: add a second part about having multiple topic
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
2013
diff
changeset
|
472 |