Show More
@@ -1,93 +1,128 b'' | |||
|
1 | 1 | # init |
|
2 | 2 | |
|
3 | 3 | $ hg init |
|
4 | 4 | $ echo a > a |
|
5 | 5 | $ hg add a |
|
6 | 6 | $ hg commit -m'a' |
|
7 | 7 | $ echo b > b |
|
8 | 8 | $ hg add b |
|
9 | 9 | $ hg commit -m'b' |
|
10 | 10 | $ hg up -C 0 |
|
11 | 11 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
12 | 12 | $ echo c > c |
|
13 | 13 | $ hg add c |
|
14 | 14 | $ hg commit -m'c' |
|
15 | 15 | created new head |
|
16 | 16 | |
|
17 | 17 | # test merging of diverged bookmarks |
|
18 | 18 | $ hg bookmark -r 1 "c@diverge" |
|
19 | 19 | $ hg bookmark -r 1 b |
|
20 | 20 | $ hg bookmark c |
|
21 | 21 | $ hg bookmarks |
|
22 | 22 | b 1:d2ae7f538514 |
|
23 | 23 | * c 2:d36c0562f908 |
|
24 | 24 | c@diverge 1:d2ae7f538514 |
|
25 | 25 | $ hg merge "c@diverge" |
|
26 | 26 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
27 | 27 | (branch merge, don't forget to commit) |
|
28 | 28 | $ hg commit -m'merge' |
|
29 | 29 | $ hg bookmarks |
|
30 | 30 | b 1:d2ae7f538514 |
|
31 | 31 | * c 3:b8f96cf4688b |
|
32 | 32 | |
|
33 | 33 | $ hg up -C 3 |
|
34 | 34 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
35 | 35 | $ echo d > d |
|
36 | 36 | $ hg add d |
|
37 | 37 | $ hg commit -m'd' |
|
38 | 38 | |
|
39 | 39 | $ hg up -C 3 |
|
40 | 40 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
41 | 41 | $ echo e > e |
|
42 | 42 | $ hg add e |
|
43 | 43 | $ hg commit -m'e' |
|
44 | 44 | created new head |
|
45 | 45 | $ hg up -C 5 |
|
46 | 46 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
47 | 47 | $ hg bookmark e |
|
48 | 48 | $ hg bookmarks |
|
49 | 49 | b 1:d2ae7f538514 |
|
50 | 50 | c 3:b8f96cf4688b |
|
51 | 51 | * e 5:26bee9c5bcf3 |
|
52 | 52 | |
|
53 | 53 | # the picked side is bookmarked |
|
54 | 54 | |
|
55 | 55 | $ hg up -C 4 |
|
56 | 56 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
57 | 57 | $ hg merge |
|
58 | 58 | abort: heads are bookmarked - please merge with an explicit rev |
|
59 | 59 | (run 'hg heads' to see all heads) |
|
60 | 60 | [255] |
|
61 | 61 | |
|
62 | 62 | # our revision is bookmarked |
|
63 | 63 | |
|
64 | 64 | $ hg up -C e |
|
65 | 65 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
66 | 66 | $ hg merge |
|
67 | 67 | abort: no matching bookmark to merge - please merge with an explicit rev or bookmark |
|
68 | 68 | (run 'hg heads' to see all heads) |
|
69 | 69 | [255] |
|
70 | 70 | |
|
71 | 71 | # merge bookmark heads |
|
72 | 72 | |
|
73 | 73 | $ hg up -C 4 |
|
74 | 74 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
75 | 75 | $ echo f > f |
|
76 | 76 | $ hg commit -Am "f" |
|
77 | 77 | adding f |
|
78 | 78 | $ hg up -C e |
|
79 | 79 | 1 files updated, 0 files merged, 2 files removed, 0 files unresolved |
|
80 | 80 | $ hg bookmarks -r 4 "e@diverged" |
|
81 | 81 | $ hg bookmarks |
|
82 | 82 | b 1:d2ae7f538514 |
|
83 | 83 | c 3:b8f96cf4688b |
|
84 | 84 | * e 5:26bee9c5bcf3 |
|
85 | 85 | e@diverged 4:a0546fcfe0fb |
|
86 | 86 | $ hg merge |
|
87 | 87 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
88 | 88 | (branch merge, don't forget to commit) |
|
89 | 89 | $ hg commit -m'merge' |
|
90 | 90 | $ hg bookmarks |
|
91 | 91 | b 1:d2ae7f538514 |
|
92 | 92 | c 3:b8f96cf4688b |
|
93 | 93 | * e 7:ca784329f0ba |
|
94 | ||
|
95 | # test warning when all heads are inactive bookmarks | |
|
96 | ||
|
97 | $ hg up -C 6 | |
|
98 | 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
|
99 | $ echo g > g | |
|
100 | $ hg commit -Am 'g' | |
|
101 | adding g | |
|
102 | $ hg bookmark -i g | |
|
103 | $ hg bookmarks | |
|
104 | b 1:d2ae7f538514 | |
|
105 | c 3:b8f96cf4688b | |
|
106 | e 7:ca784329f0ba | |
|
107 | g 8:04dd21731d95 | |
|
108 | $ hg heads | |
|
109 | changeset: 8:04dd21731d95 | |
|
110 | bookmark: g | |
|
111 | tag: tip | |
|
112 | parent: 6:be381d1126a0 | |
|
113 | user: test | |
|
114 | date: Thu Jan 01 00:00:00 1970 +0000 | |
|
115 | summary: g | |
|
116 | ||
|
117 | changeset: 7:ca784329f0ba | |
|
118 | bookmark: e | |
|
119 | parent: 5:26bee9c5bcf3 | |
|
120 | parent: 4:a0546fcfe0fb | |
|
121 | user: test | |
|
122 | date: Thu Jan 01 00:00:00 1970 +0000 | |
|
123 | summary: merge | |
|
124 | ||
|
125 | $ hg merge | |
|
126 | abort: heads are bookmarked - please merge with an explicit rev | |
|
127 | (run 'hg heads' to see all heads) | |
|
128 | [255] |
General Comments 0
You need to be logged in to leave comments.
Login now