Mercurial > evolve
annotate tests/test-rewind.t @ 6875:6209891ff220
topic: add `short` keyword argument to callers of common.formatfqbn()
The default value (True) is the same as in common.formatfqbn().
author | Anton Shestakov <av6@dwimlabs.net> |
---|---|
date | Thu, 19 Sep 2024 16:48:48 +0400 |
parents | abbc021c6f68 |
children | fd039a7f0c3c |
rev | line source |
---|---|
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
1 $ . $TESTDIR/testlib/common.sh |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
2 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
3 Global setup |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
4 ============ |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
5 |
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
6 $ cat >> $HGRCPATH << EOF |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
7 > [phases] |
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
8 > publish = false |
4722
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
9 > [alias] |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
10 > glf = log -GT "{rev}: {desc} ({files})" |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
11 > glhf = log -GT "{rev}:{node|short} {desc} ({files})" |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
12 > [extensions] |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
13 > evolve = |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
14 > EOF |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
15 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
16 $ hg init rewind-testing-base |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
17 $ cd rewind-testing-base |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
18 $ echo a > root |
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
19 $ hg ci -qAm 'c_ROOT' |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
20 $ echo a > A |
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
21 $ hg ci -qAm 'c_A0' |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
22 $ echo a > B |
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
23 $ hg ci -qAm 'c_B0' |
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
24 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
25 $ hg log -G |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
26 @ changeset: 2:7e594302a05d |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
27 | tag: tip |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
28 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
29 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
30 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
31 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
32 o changeset: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
33 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
34 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
35 | summary: c_A0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
36 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
37 o changeset: 0:eba9c2249fe7 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
38 user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
39 date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
40 summary: c_ROOT |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
41 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
42 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
43 $ cd .. |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
44 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
45 Rewinding to a single changeset |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
46 =============================== |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
47 |
5448
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
48 $ hg clone rewind-testing-base rewind-testing-single-prunes |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
49 updating to branch default |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
50 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
5448
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
51 $ cd rewind-testing-single-prunes |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
52 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
53 Prune changeset unrelated to the working copy |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
54 --------------------------------------------- |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
55 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
56 update to an unrelated changeset |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
57 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
58 $ hg up 'desc("c_ROOT")' |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
59 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
60 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
61 prune the head |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
62 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
63 $ hg prune -r 'desc("c_B0")' |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
64 1 changesets pruned |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
65 $ hg log -G |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
66 o changeset: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
67 | tag: tip |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
68 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
69 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
70 | summary: c_A0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
71 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
72 @ changeset: 0:eba9c2249fe7 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
73 user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
74 date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
75 summary: c_ROOT |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
76 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
77 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
78 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
79 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
80 $ hg rewind --hidden --to 'desc("c_B0")' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
81 rewinding a pruned commit to 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
82 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
83 actual rewind |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
84 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
85 $ hg rewind --hidden --to 'desc("c_B0")' |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
86 rewound to 1 changesets |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
87 $ hg debugobsolete |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
88 7e594302a05d3769b27be88fc3cdfd39d7498498 0 {579f120ba91885449adc92eedf48ef3569742cee} (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'} |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
89 7e594302a05d3769b27be88fc3cdfd39d7498498 073989a581cf430a844192364fa37606357cbbc2 4 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
90 $ hg obslog -r 'desc("c_B0")' --no-origin |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
91 o 073989a581cf (3) c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
92 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
93 x 7e594302a05d (2) c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
94 pruned using prune by test (Thu Jan 01 00:00:00 1970 +0000) |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
95 meta-changed(meta) as 073989a581cf using rewind by test (Thu Jan 01 00:00:00 1970 +0000) |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
96 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
97 $ hg obslog -r 'desc("c_B0")' |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
98 o 073989a581cf (3) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
99 | meta-changed(meta) from 7e594302a05d using rewind by test (Thu Jan 01 00:00:00 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
100 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
101 x 7e594302a05d (2) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
102 pruned using prune by test (Thu Jan 01 00:00:00 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
103 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
104 $ hg log -G |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
105 o changeset: 3:073989a581cf |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
106 | tag: tip |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
107 | parent: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
108 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
109 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
110 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
111 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
112 o changeset: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
113 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
114 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
115 | summary: c_A0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
116 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
117 @ changeset: 0:eba9c2249fe7 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
118 user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
119 date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
120 summary: c_ROOT |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
121 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
122 XXX-TODO: fix the obsfate from "meta-changed as 3" to "identical" or something. |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
123 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
124 $ hg log -G --hidden |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
125 o changeset: 3:073989a581cf |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
126 | tag: tip |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
127 | parent: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
128 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
129 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
130 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
131 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
132 | x changeset: 2:7e594302a05d |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
133 |/ user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
134 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
135 | obsolete: meta-changed using rewind as 3:073989a581cf |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
136 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
137 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
138 o changeset: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
139 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
140 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
141 | summary: c_A0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
142 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
143 @ changeset: 0:eba9c2249fe7 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
144 user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
145 date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
146 summary: c_ROOT |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
147 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
148 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
149 Other independent rewind creates a different revision |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
150 ----------------------------------------------------- |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
151 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
152 note: we use "default-date" to make it a "different rewind" |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
153 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
154 $ echo '[devel]' >> $HGRCPATH |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
155 $ echo 'default-date = 1 0' >> $HGRCPATH |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
156 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
157 $ hg prune 'desc("c_B0")' |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
158 1 changesets pruned |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
159 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
160 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
161 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
162 $ hg rewind --hidden --to 'min(desc("c_B0"))' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
163 rewinding a pruned commit to 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
164 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
165 actual rewind |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
166 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
167 $ hg rewind --hidden --to 'min(desc("c_B0"))' |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
168 rewound to 1 changesets |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
169 $ hg debugobsolete |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
170 7e594302a05d3769b27be88fc3cdfd39d7498498 0 {579f120ba91885449adc92eedf48ef3569742cee} (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'} |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
171 7e594302a05d3769b27be88fc3cdfd39d7498498 073989a581cf430a844192364fa37606357cbbc2 4 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
172 073989a581cf430a844192364fa37606357cbbc2 0 {579f120ba91885449adc92eedf48ef3569742cee} (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'} |
4899 | 173 7e594302a05d3769b27be88fc3cdfd39d7498498 b13b032065ef57a68d9a4cead38ba0f34f95529b 4 (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
174 $ hg obslog -r 'desc("c_B0")' --all --no-origin |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
175 x 073989a581cf (3) c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
176 | pruned using prune by test (Thu Jan 01 00:00:01 1970 +0000) |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
177 | |
4899 | 178 | o b13b032065ef (4) c_B0 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
179 |/ |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
180 x 7e594302a05d (2) c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
181 pruned using prune by test (Thu Jan 01 00:00:00 1970 +0000) |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
182 meta-changed(meta) as 073989a581cf using rewind by test (Thu Jan 01 00:00:00 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
183 meta-changed(meta) as b13b032065ef using rewind by test (Thu Jan 01 00:00:01 1970 +0000) |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
184 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
185 $ hg obslog -r 'desc("c_B0")' --all |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
186 x 073989a581cf (3) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
187 | meta-changed(meta) from 7e594302a05d using rewind by test (Thu Jan 01 00:00:00 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
188 | pruned using prune by test (Thu Jan 01 00:00:01 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
189 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
190 | o b13b032065ef (4) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
191 |/ meta-changed(meta) from 7e594302a05d using rewind by test (Thu Jan 01 00:00:01 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
192 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
193 x 7e594302a05d (2) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
194 pruned using prune by test (Thu Jan 01 00:00:00 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
195 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
196 $ hg log -G |
4899 | 197 o changeset: 4:b13b032065ef |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
198 | tag: tip |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
199 | parent: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
200 | user: test |
4899 | 201 | date: Thu Jan 01 00:00:00 1970 +0000 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
202 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
203 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
204 o changeset: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
205 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
206 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
207 | summary: c_A0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
208 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
209 @ changeset: 0:eba9c2249fe7 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
210 user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
211 date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
212 summary: c_ROOT |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
213 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
214 $ hg log -G --hidden |
4899 | 215 o changeset: 4:b13b032065ef |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
216 | tag: tip |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
217 | parent: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
218 | user: test |
4899 | 219 | date: Thu Jan 01 00:00:00 1970 +0000 |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
220 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
221 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
222 | x changeset: 3:073989a581cf |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
223 |/ parent: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
224 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
225 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
226 | obsolete: pruned using prune |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
227 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
228 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
229 | x changeset: 2:7e594302a05d |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
230 |/ user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
231 | date: Thu Jan 01 00:00:00 1970 +0000 |
4899 | 232 | obsolete: meta-changed using rewind as 4:b13b032065ef |
3858
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
233 | obsolete: meta-changed using rewind as 3:073989a581cf |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
234 | summary: c_B0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
235 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
236 o changeset: 1:579f120ba918 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
237 | user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
238 | date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
239 | summary: c_A0 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
240 | |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
241 @ changeset: 0:eba9c2249fe7 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
242 user: test |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
243 date: Thu Jan 01 00:00:00 1970 +0000 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
244 summary: c_ROOT |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
245 |
bb4f5ad63877
rewind: add a proto version of the command
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
246 $ cd .. |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
247 |
5448
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
248 $ hg clone rewind-testing-base rewind-testing-single-amends |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
249 updating to branch default |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
250 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
251 $ cd rewind-testing-single-amends |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
252 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
253 Rewind a simple amend - creating content-divergence |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
254 --------------------------------------------------- |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
255 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
256 $ echo BB > B |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
257 $ hg amend -m 'c_B1' |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
258 $ hg log -G |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
259 @ changeset: 3:25c8f5ab0c3b |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
260 | tag: tip |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
261 | parent: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
262 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
263 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
264 | summary: c_B1 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
265 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
266 o changeset: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
267 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
268 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
269 | summary: c_A0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
270 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
271 o changeset: 0:eba9c2249fe7 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
272 user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
273 date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
274 summary: c_ROOT |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
275 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
276 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
277 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
278 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
279 $ hg rewind --from 'desc("c_B1")' --as-divergence --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
280 recreating 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
281 $ hg rewind --hidden --to 'desc("c_B0")' --as-divergence --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
282 recreating 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
283 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
284 actual rewind |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
285 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
286 $ hg rewind --hidden --to 'desc("c_B0")' --as-divergence |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
287 2 new content-divergent changesets |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
288 rewound to 1 changesets |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
289 $ hg debugobsolete |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
290 7e594302a05d3769b27be88fc3cdfd39d7498498 25c8f5ab0c3bb569ec672570f1a901be4c6f032b 0 (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
4899 | 291 7e594302a05d3769b27be88fc3cdfd39d7498498 b13b032065ef57a68d9a4cead38ba0f34f95529b 4 (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
292 $ hg obslog --rev 'desc("c_B0")' --no-origin |
4899 | 293 * b13b032065ef (4) c_B0 |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
294 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
295 x 7e594302a05d (2) c_B0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
296 rewritten(description, content) as 25c8f5ab0c3b using amend by test (Thu Jan 01 00:00:01 1970 +0000) |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
297 meta-changed(meta) as b13b032065ef using rewind by test (Thu Jan 01 00:00:01 1970 +0000) |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
298 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
299 $ hg obslog --rev 'desc("c_B0")' |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
300 * b13b032065ef (4) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
301 | meta-changed(meta) from 7e594302a05d using rewind by test (Thu Jan 01 00:00:01 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
302 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
303 x 7e594302a05d (2) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
304 |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
305 $ hg log -G |
4899 | 306 * changeset: 4:b13b032065ef |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
307 | tag: tip |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
308 | parent: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
309 | user: test |
4899 | 310 | date: Thu Jan 01 00:00:00 1970 +0000 |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
311 | instability: content-divergent |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
312 | summary: c_B0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
313 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
314 | @ changeset: 3:25c8f5ab0c3b |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
315 |/ parent: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
316 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
317 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
318 | instability: content-divergent |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
319 | summary: c_B1 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
320 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
321 o changeset: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
322 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
323 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
324 | summary: c_A0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
325 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
326 o changeset: 0:eba9c2249fe7 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
327 user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
328 date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
329 summary: c_ROOT |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
330 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
331 $ hg log -G --hidden |
4899 | 332 * changeset: 4:b13b032065ef |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
333 | tag: tip |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
334 | parent: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
335 | user: test |
4899 | 336 | date: Thu Jan 01 00:00:00 1970 +0000 |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
337 | instability: content-divergent |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
338 | summary: c_B0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
339 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
340 | @ changeset: 3:25c8f5ab0c3b |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
341 |/ parent: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
342 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
343 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
344 | instability: content-divergent |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
345 | summary: c_B1 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
346 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
347 | x changeset: 2:7e594302a05d |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
348 |/ user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
349 | date: Thu Jan 01 00:00:00 1970 +0000 |
4899 | 350 | obsolete: meta-changed using rewind as 4:b13b032065ef |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
351 | obsolete: rewritten using amend as 3:25c8f5ab0c3b |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
352 | summary: c_B0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
353 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
354 o changeset: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
355 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
356 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
357 | summary: c_A0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
358 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
359 o changeset: 0:eba9c2249fe7 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
360 user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
361 date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
362 summary: c_ROOT |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
363 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
364 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
365 rewind --dry-run output when rewinding with relevant divergence |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
366 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
367 $ hg rewind --to 'min(desc("c_B0"))' --hidden --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
368 abort: rewind confused by divergence on 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
369 (solve divergence first or use "--as-divergence") |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
370 [255] |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
371 $ hg rewind --to 'min(desc("c_B0"))' --hidden --as-divergence --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
372 recreating 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
373 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
374 cleanup |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
375 |
3860
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
376 $ hg prune 'max(desc("c_B0"))' |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
377 1 changesets pruned |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
378 $ hg log -G |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
379 @ changeset: 3:25c8f5ab0c3b |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
380 | tag: tip |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
381 | parent: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
382 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
383 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
384 | summary: c_B1 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
385 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
386 o changeset: 1:579f120ba918 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
387 | user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
388 | date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
389 | summary: c_A0 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
390 | |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
391 o changeset: 0:eba9c2249fe7 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
392 user: test |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
393 date: Thu Jan 01 00:00:00 1970 +0000 |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
394 summary: c_ROOT |
fa184c5edfe8
rewind: test rewinding an amended changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3859
diff
changeset
|
395 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
396 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
397 Rewind a simple amend - obsoleting the current latest successor |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
398 --------------------------------------------------------------- |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
399 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
400 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
401 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
402 $ hg rewind --hidden --to 'min(desc("c_B0"))' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
403 rewinding 25c8f5ab0c3b to 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
404 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
405 actual rewind |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
406 |
5446
5fc54b8f3f84
tests: move default-date manipulation closer to the commands that need it
Anton Shestakov <av6@dwimlabs.net>
parents:
5445
diff
changeset
|
407 $ echo 'default-date = 2 0' >> $HGRCPATH |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
408 $ hg rewind --hidden --to 'min(desc("c_B0"))' |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
409 rewound to 1 changesets |
3862
8d3eed113b77
rewind: add a message about obsolete changeset
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3861
diff
changeset
|
410 (1 changesets obsoleted) |
4899 | 411 working directory is now at 837cd997bb05 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
412 $ hg debugobsolete |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
413 7e594302a05d3769b27be88fc3cdfd39d7498498 25c8f5ab0c3bb569ec672570f1a901be4c6f032b 0 (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
4899 | 414 7e594302a05d3769b27be88fc3cdfd39d7498498 b13b032065ef57a68d9a4cead38ba0f34f95529b 4 (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
415 b13b032065ef57a68d9a4cead38ba0f34f95529b 0 {579f120ba91885449adc92eedf48ef3569742cee} (Thu Jan 01 00:00:01 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'} | |
416 7e594302a05d3769b27be88fc3cdfd39d7498498 837cd997bb05a27f8ed7d1ba3ff1e8422b9b464e 4 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
417 25c8f5ab0c3bb569ec672570f1a901be4c6f032b 837cd997bb05a27f8ed7d1ba3ff1e8422b9b464e 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '11', 'operation': 'rewind', 'user': 'test'} | |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
418 $ hg obslog --rev 'desc("c_B0")' --no-origin |
4899 | 419 @ 837cd997bb05 (5) c_B0 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
420 |\ |
3863
c31be22d1d90
rewind: update the working copy if it gets obsoleted
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3862
diff
changeset
|
421 x | 25c8f5ab0c3b (3) c_B1 |
4899 | 422 |/ rewritten(description, meta, content) as 837cd997bb05 using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
423 | |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
424 x 7e594302a05d (2) c_B0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
425 rewritten(description, content) as 25c8f5ab0c3b using amend by test (Thu Jan 01 00:00:01 1970 +0000) |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
426 meta-changed(meta) as 837cd997bb05 using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
427 meta-changed(meta) as b13b032065ef using rewind by test (Thu Jan 01 00:00:01 1970 +0000) |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
428 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
429 $ hg obslog --rev 'desc("c_B0")' |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
430 @ 837cd997bb05 (5) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
431 |\ rewritten(description, meta, content) from 25c8f5ab0c3b using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
432 | | meta-changed(meta) from 7e594302a05d using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
433 | | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
434 x | 25c8f5ab0c3b (3) c_B1 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
435 |/ rewritten(description, content) from 7e594302a05d using amend by test (Thu Jan 01 00:00:01 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
436 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
437 x 7e594302a05d (2) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
438 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
439 $ hg log -G |
4899 | 440 @ changeset: 5:837cd997bb05 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
441 | tag: tip |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
442 | parent: 1:579f120ba918 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
443 | user: test |
4899 | 444 | date: Thu Jan 01 00:00:00 1970 +0000 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
445 | summary: c_B0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
446 | |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
447 o changeset: 1:579f120ba918 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
448 | user: test |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
449 | date: Thu Jan 01 00:00:00 1970 +0000 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
450 | summary: c_A0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
451 | |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
452 o changeset: 0:eba9c2249fe7 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
453 user: test |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
454 date: Thu Jan 01 00:00:00 1970 +0000 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
455 summary: c_ROOT |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
456 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
457 $ hg log -G --hidden |
4899 | 458 @ changeset: 5:837cd997bb05 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
459 | tag: tip |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
460 | parent: 1:579f120ba918 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
461 | user: test |
4899 | 462 | date: Thu Jan 01 00:00:00 1970 +0000 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
463 | summary: c_B0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
464 | |
4899 | 465 | x changeset: 4:b13b032065ef |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
466 |/ parent: 1:579f120ba918 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
467 | user: test |
4899 | 468 | date: Thu Jan 01 00:00:00 1970 +0000 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
469 | obsolete: pruned using prune |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
470 | summary: c_B0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
471 | |
3863
c31be22d1d90
rewind: update the working copy if it gets obsoleted
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3862
diff
changeset
|
472 | x changeset: 3:25c8f5ab0c3b |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
473 |/ parent: 1:579f120ba918 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
474 | user: test |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
475 | date: Thu Jan 01 00:00:00 1970 +0000 |
4899 | 476 | obsolete: rewritten using rewind as 5:837cd997bb05 |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
477 | summary: c_B1 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
478 | |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
479 | x changeset: 2:7e594302a05d |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
480 |/ user: test |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
481 | date: Thu Jan 01 00:00:00 1970 +0000 |
4899 | 482 | obsolete: meta-changed using rewind as 4:b13b032065ef |
483 | obsolete: meta-changed using rewind as 5:837cd997bb05 | |
3861
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
484 | obsolete: rewritten using amend as 3:25c8f5ab0c3b |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
485 | summary: c_B0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
486 | |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
487 o changeset: 1:579f120ba918 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
488 | user: test |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
489 | date: Thu Jan 01 00:00:00 1970 +0000 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
490 | summary: c_A0 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
491 | |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
492 o changeset: 0:eba9c2249fe7 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
493 user: test |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
494 date: Thu Jan 01 00:00:00 1970 +0000 |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
495 summary: c_ROOT |
bbe635dfd75c
rewind: obsolete latest successors unless instructed otherwise
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3860
diff
changeset
|
496 |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
497 $ cd .. |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
498 |
5448
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
499 $ hg clone rewind-testing-base rewind-testing-single-split-fold |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
500 updating to branch default |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
501 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
502 $ cd rewind-testing-single-split-fold |
a0e0352f96e0
tests: move hg clone above case description in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5447
diff
changeset
|
503 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
504 Rewind a simple split |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
505 --------------------- |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
506 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
507 $ echo C > C |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
508 $ echo D > D |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
509 $ hg ci -qAm 'c_CD0' |
5449
ab5e857506ef
tests: shorten and simplify global setup section in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5448
diff
changeset
|
510 $ hg split --config ui.interactive=yes << EOF |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
511 > y |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
512 > f |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
513 > d |
4294
8974a05a49fa
split: rework the prompt to be more standard
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
4293
diff
changeset
|
514 > c |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
515 > EOF |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
516 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
517 adding C |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
518 adding D |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
519 diff --git a/C b/C |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
520 new file mode 100644 |
4712
e2c548cc83b5
tests: update output for shorted prompts from Mercurial
Martin von Zweigbergk <martinvonz@google.com>
parents:
4624
diff
changeset
|
521 examine changes to 'C'? |
e2c548cc83b5
tests: update output for shorted prompts from Mercurial
Martin von Zweigbergk <martinvonz@google.com>
parents:
4624
diff
changeset
|
522 (enter ? for help) [Ynesfdaq?] y |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
523 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
524 @@ -0,0 +1,1 @@ |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
525 +C |
4712
e2c548cc83b5
tests: update output for shorted prompts from Mercurial
Martin von Zweigbergk <martinvonz@google.com>
parents:
4624
diff
changeset
|
526 record change 1/2 to 'C'? |
e2c548cc83b5
tests: update output for shorted prompts from Mercurial
Martin von Zweigbergk <martinvonz@google.com>
parents:
4624
diff
changeset
|
527 (enter ? for help) [Ynesfdaq?] f |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
528 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
529 diff --git a/D b/D |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
530 new file mode 100644 |
4712
e2c548cc83b5
tests: update output for shorted prompts from Mercurial
Martin von Zweigbergk <martinvonz@google.com>
parents:
4624
diff
changeset
|
531 examine changes to 'D'? |
e2c548cc83b5
tests: update output for shorted prompts from Mercurial
Martin von Zweigbergk <martinvonz@google.com>
parents:
4624
diff
changeset
|
532 (enter ? for help) [Ynesfdaq?] d |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
533 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
534 created new head |
4294
8974a05a49fa
split: rework the prompt to be more standard
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
4293
diff
changeset
|
535 continue splitting? [Ycdq?] c |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
536 $ hg log -G |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
537 @ changeset: 5:9576e80d6851 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
538 | tag: tip |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
539 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
540 | date: Thu Jan 01 00:00:02 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
541 | summary: c_CD0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
542 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
543 o changeset: 4:a0316c4c5417 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
544 | parent: 2:7e594302a05d |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
545 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
546 | date: Thu Jan 01 00:00:02 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
547 | summary: c_CD0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
548 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
549 o changeset: 2:7e594302a05d |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
550 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
551 | date: Thu Jan 01 00:00:00 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
552 | summary: c_B0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
553 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
554 o changeset: 1:579f120ba918 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
555 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
556 | date: Thu Jan 01 00:00:00 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
557 | summary: c_A0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
558 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
559 o changeset: 0:eba9c2249fe7 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
560 user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
561 date: Thu Jan 01 00:00:00 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
562 summary: c_ROOT |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
563 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
564 $ hg debugobsolete |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
565 49fb7d900906b0a3d329e90da4dcb0a7582d3b6e a0316c4c54179357e71d068fb8884678ebc7c351 9576e80d6851ce79cd535e2dc5fa01b444d89a39 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '12', 'operation': 'split', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
566 $ hg obslog --all --no-origin |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
567 @ 9576e80d6851 (5) c_CD0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
568 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
569 | o a0316c4c5417 (4) c_CD0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
570 |/ |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
571 x 49fb7d900906 (3) c_CD0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
572 split(parent, content) as 9576e80d6851, a0316c4c5417 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
573 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
574 $ hg obslog --all |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
575 @ 9576e80d6851 (5) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
576 | split(parent, content) from 49fb7d900906 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
577 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
578 | o a0316c4c5417 (4) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
579 |/ split(parent, content) from 49fb7d900906 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
580 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
581 x 49fb7d900906 (3) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
582 |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
583 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
584 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
585 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
586 $ hg rewind --from 'desc("c_CD0")' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
587 rewinding a0316c4c5417 9576e80d6851 to 1 changesets: 49fb7d900906 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
588 $ hg rewind --hidden --to 'min(desc("c_CD0"))' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
589 rewinding a0316c4c5417 9576e80d6851 to 1 changesets: 49fb7d900906 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
590 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
591 actual rewind |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
592 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
593 $ hg rewind --hidden --to 'min(desc("c_CD0"))' |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
594 rewound to 1 changesets |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
595 (2 changesets obsoleted) |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
596 working directory is now at 4535d0af405c |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
597 $ hg debugobsolete |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
598 49fb7d900906b0a3d329e90da4dcb0a7582d3b6e a0316c4c54179357e71d068fb8884678ebc7c351 9576e80d6851ce79cd535e2dc5fa01b444d89a39 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '12', 'operation': 'split', 'user': 'test'} |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
599 49fb7d900906b0a3d329e90da4dcb0a7582d3b6e 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b 4 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
600 9576e80d6851ce79cd535e2dc5fa01b444d89a39 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '14', 'fold-id': 'eeda726b', 'fold-idx': '1', 'fold-size': '2', 'operation': 'rewind', 'user': 'test'} |
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
601 a0316c4c54179357e71d068fb8884678ebc7c351 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '10', 'fold-id': 'eeda726b', 'fold-idx': '2', 'fold-size': '2', 'operation': 'rewind', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
602 $ hg obslog --no-origin |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
603 @ 4535d0af405c (6) c_CD0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
604 |\ |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
605 | \ |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
606 | |\ |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
607 | x | 9576e80d6851 (5) c_CD0 |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
608 |/ / folded(meta, parent, content) as 4535d0af405c using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
609 | | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
610 | x a0316c4c5417 (4) c_CD0 |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
611 |/ folded(meta, content) as 4535d0af405c using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
612 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
613 x 49fb7d900906 (3) c_CD0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
614 meta-changed(meta) as 4535d0af405c using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
615 split(parent, content) as 9576e80d6851, a0316c4c5417 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
616 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
617 $ hg obslog |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
618 @ 4535d0af405c (6) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
619 |\ meta-changed(meta) from 49fb7d900906 using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
620 | | folded(meta, parent, content) from 9576e80d6851, a0316c4c5417 using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
621 | | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
622 | \ |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
623 | |\ |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
624 | x | 9576e80d6851 (5) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
625 |/ / split(parent, content) from 49fb7d900906 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
626 | | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
627 | x a0316c4c5417 (4) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
628 |/ split(parent, content) from 49fb7d900906 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
629 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
630 x 49fb7d900906 (3) c_CD0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
631 |
3864
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
632 $ hg log -G |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
633 @ changeset: 6:4535d0af405c |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
634 | tag: tip |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
635 | parent: 2:7e594302a05d |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
636 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
637 | date: Thu Jan 01 00:00:02 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
638 | summary: c_CD0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
639 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
640 o changeset: 2:7e594302a05d |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
641 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
642 | date: Thu Jan 01 00:00:00 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
643 | summary: c_B0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
644 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
645 o changeset: 1:579f120ba918 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
646 | user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
647 | date: Thu Jan 01 00:00:00 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
648 | summary: c_A0 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
649 | |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
650 o changeset: 0:eba9c2249fe7 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
651 user: test |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
652 date: Thu Jan 01 00:00:00 1970 +0000 |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
653 summary: c_ROOT |
0254c96ce108
rewind: add a test for rewinding a split
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3863
diff
changeset
|
654 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
655 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
656 Rewind a fold |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
657 ------------- |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
658 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
659 $ echo 'default-date = 3 0' >> $HGRCPATH |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
660 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
661 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
662 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
663 $ hg rewind --from . --hidden --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
664 rewinding 4535d0af405c to 2 changesets: a0316c4c5417 9576e80d6851 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
665 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
666 $ hg rewind --to '9576e80d6851+a0316c4c5417' --hidden --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
667 rewinding 4535d0af405c to 2 changesets: a0316c4c5417 9576e80d6851 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
668 $ hg rewind --to '9576e80d6851' --hidden --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
669 rewinding 4535d0af405c to 2 changesets: a0316c4c5417 9576e80d6851 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
670 $ hg rewind --to 'a0316c4c5417' --hidden --dry-run |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
671 rewinding 4535d0af405c to 2 changesets: a0316c4c5417 9576e80d6851 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
672 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
673 $ hg rewind --to '9576e80d6851' --exact --hidden --dry-run |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
674 rewinding 4535d0af405c to 2 changesets: a0316c4c5417 9576e80d6851 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
675 $ hg rewind --to 'a0316c4c5417' --exact --hidden --dry-run |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
676 rewinding 4535d0af405c to 2 changesets: a0316c4c5417 9576e80d6851 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
677 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
678 actual rewind |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
679 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
680 $ hg rewind --to '9576e80d6851+a0316c4c5417' --hidden |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
681 rewound to 2 changesets |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
682 (1 changesets obsoleted) |
4899 | 683 working directory is now at 95d72d892df7 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
684 $ hg debugobsolete |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
685 49fb7d900906b0a3d329e90da4dcb0a7582d3b6e a0316c4c54179357e71d068fb8884678ebc7c351 9576e80d6851ce79cd535e2dc5fa01b444d89a39 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '12', 'operation': 'split', 'user': 'test'} |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
686 49fb7d900906b0a3d329e90da4dcb0a7582d3b6e 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b 4 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
687 9576e80d6851ce79cd535e2dc5fa01b444d89a39 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '14', 'fold-id': 'eeda726b', 'fold-idx': '1', 'fold-size': '2', 'operation': 'rewind', 'user': 'test'} |
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
688 a0316c4c54179357e71d068fb8884678ebc7c351 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b 0 (Thu Jan 01 00:00:02 1970 +0000) {'ef1': '10', 'fold-id': 'eeda726b', 'fold-idx': '2', 'fold-size': '2', 'operation': 'rewind', 'user': 'test'} |
4899 | 689 a0316c4c54179357e71d068fb8884678ebc7c351 e76375de0bfc9c59bdd91067c901f3eed7d6c8fe 4 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
690 9576e80d6851ce79cd535e2dc5fa01b444d89a39 95d72d892df7fec59107e10914c5729bdf03665f 4 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
691 4535d0af405c1bf35f37b35f26ec6f9acfa6fe0b e76375de0bfc9c59bdd91067c901f3eed7d6c8fe 95d72d892df7fec59107e10914c5729bdf03665f 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '14', 'operation': 'rewind', 'user': 'test'} | |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
692 $ hg obslog -r -2: --no-origin |
4899 | 693 @ 95d72d892df7 (8) c_CD0 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
694 |\ |
4899 | 695 +---o e76375de0bfc (7) c_CD0 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
696 | | | |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
697 x---+ 4535d0af405c (6) c_CD0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
698 |\| | split(meta, parent, content) as 95d72d892df7, e76375de0bfc using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
699 | | | |
4899 | 700 | x | 9576e80d6851 (5) c_CD0 |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
701 |/ / folded(meta, parent, content) as 4535d0af405c using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
4899 | 702 | | rewritten(meta, parent) as 95d72d892df7 using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
703 | | |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
704 | x a0316c4c5417 (4) c_CD0 |
5599
ba8bc1b0acd2
rewind: actually track folds using fold-* metadata in obsmarkers
Anton Shestakov <av6@dwimlabs.net>
parents:
5544
diff
changeset
|
705 |/ folded(meta, content) as 4535d0af405c using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
706 | meta-changed(meta) as e76375de0bfc using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
707 | |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
708 x 49fb7d900906 (3) c_CD0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
709 meta-changed(meta) as 4535d0af405c using rewind by test (Thu Jan 01 00:00:02 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
710 split(parent, content) as 9576e80d6851, a0316c4c5417 using split by test (Thu Jan 01 00:00:02 1970 +0000) |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
711 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
712 $ hg log -G |
4899 | 713 @ changeset: 8:95d72d892df7 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
714 | tag: tip |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
715 | user: test |
4899 | 716 | date: Thu Jan 01 00:00:02 1970 +0000 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
717 | summary: c_CD0 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
718 | |
4899 | 719 o changeset: 7:e76375de0bfc |
3866
de42d00d6ee2
rewind: use rewinded parent when creating multiple changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3865
diff
changeset
|
720 | parent: 2:7e594302a05d |
de42d00d6ee2
rewind: use rewinded parent when creating multiple changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3865
diff
changeset
|
721 | user: test |
4899 | 722 | date: Thu Jan 01 00:00:02 1970 +0000 |
3866
de42d00d6ee2
rewind: use rewinded parent when creating multiple changesets
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3865
diff
changeset
|
723 | summary: c_CD0 |
3865
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
724 | |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
725 o changeset: 2:7e594302a05d |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
726 | user: test |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
727 | date: Thu Jan 01 00:00:00 1970 +0000 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
728 | summary: c_B0 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
729 | |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
730 o changeset: 1:579f120ba918 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
731 | user: test |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
732 | date: Thu Jan 01 00:00:00 1970 +0000 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
733 | summary: c_A0 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
734 | |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
735 o changeset: 0:eba9c2249fe7 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
736 user: test |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
737 date: Thu Jan 01 00:00:00 1970 +0000 |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
738 summary: c_ROOT |
b945f2dae587
rewind: add a test for rewinding a fold
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3864
diff
changeset
|
739 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
740 $ cd .. |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
741 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
742 Rewinding a stack |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
743 ================= |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
744 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
745 $ hg clone rewind-testing-base rewind-testing-stack |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
746 updating to branch default |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
747 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
748 $ cd rewind-testing-stack |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
749 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
750 Rewinding the top of the stack only |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
751 ----------------------------------- |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
752 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
753 $ hg up 'desc("c_A0")' |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
754 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
755 $ echo AA >> A |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
756 $ hg amend -m 'c_A1' |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
757 1 new orphan changesets |
5450
64ff1b7c0481
tests: remove unnecessary command flags from test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5449
diff
changeset
|
758 $ hg evolve --update |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
759 move:[2] c_B0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
760 atop:[3] c_A1 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
761 working directory is now at a65fceb2324a |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
762 $ hg debugobsolete |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
763 579f120ba91885449adc92eedf48ef3569742cee d952d1794ff657f5c2a82225d2e6307ed930b32f 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
764 7e594302a05d3769b27be88fc3cdfd39d7498498 a65fceb2324ae1eb1231610193d24a5fa02c7c0e 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '4', 'operation': 'evolve', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
765 $ hg obslog -r 'desc("c_A1")::' --no-origin |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
766 @ a65fceb2324a (4) c_B0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
767 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
768 | o d952d1794ff6 (3) c_A1 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
769 | | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
770 | x 579f120ba918 (1) c_A0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
771 | rewritten(description, content) as d952d1794ff6 using amend by test (Thu Jan 01 00:00:03 1970 +0000) |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
772 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
773 x 7e594302a05d (2) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
774 rebased(parent) as a65fceb2324a using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
775 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
776 $ hg obslog -r 'desc("c_A1")::' |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
777 @ a65fceb2324a (4) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
778 | rebased(parent) from 7e594302a05d using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
779 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
780 | o d952d1794ff6 (3) c_A1 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
781 | | rewritten(description, content) from 579f120ba918 using amend by test (Thu Jan 01 00:00:03 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
782 | | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
783 | x 579f120ba918 (1) c_A0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
784 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
785 x 7e594302a05d (2) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
786 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
787 $ hg log -G |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
788 @ changeset: 4:a65fceb2324a |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
789 | tag: tip |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
790 | user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
791 | date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
792 | summary: c_B0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
793 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
794 o changeset: 3:d952d1794ff6 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
795 | parent: 0:eba9c2249fe7 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
796 | user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
797 | date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
798 | summary: c_A1 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
799 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
800 o changeset: 0:eba9c2249fe7 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
801 user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
802 date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
803 summary: c_ROOT |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
804 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
805 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
806 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
807 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
808 $ hg rewind --hidden --to 'min(desc(c_B0))' --exact --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
809 rewinding a65fceb2324a to 1 changesets: 7e594302a05d |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
810 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
811 actual rewind |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
812 |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
813 $ hg rewind --hidden --to 'min(desc(c_B0))' --exact |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
814 1 new orphan changesets |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
815 rewound to 1 changesets |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
816 (1 changesets obsoleted) |
4899 | 817 working directory is now at ac979e0aac4e |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
818 $ hg debugobsolete |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
819 579f120ba91885449adc92eedf48ef3569742cee d952d1794ff657f5c2a82225d2e6307ed930b32f 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
820 7e594302a05d3769b27be88fc3cdfd39d7498498 a65fceb2324ae1eb1231610193d24a5fa02c7c0e 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '4', 'operation': 'evolve', 'user': 'test'} |
4899 | 821 7e594302a05d3769b27be88fc3cdfd39d7498498 ac979e0aac4e63ccbbf88ac33942192942302766 4 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
822 a65fceb2324ae1eb1231610193d24a5fa02c7c0e ac979e0aac4e63ccbbf88ac33942192942302766 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
823 $ hg obslog --no-origin |
4899 | 824 @ ac979e0aac4e (5) c_B0 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
825 |\ |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
826 | x a65fceb2324a (4) c_B0 |
4899 | 827 |/ rewritten(meta, parent) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
828 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
829 x 7e594302a05d (2) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
830 rebased(parent) as a65fceb2324a using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
831 meta-changed(meta) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
832 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
833 $ hg obslog |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
834 @ ac979e0aac4e (5) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
835 |\ meta-changed(meta) from 7e594302a05d using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
836 | | rewritten(meta, parent) from a65fceb2324a using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
837 | | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
838 | x a65fceb2324a (4) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
839 |/ rebased(parent) from 7e594302a05d using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
840 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
841 x 7e594302a05d (2) c_B0 |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
842 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
843 $ hg log -G |
4899 | 844 @ changeset: 5:ac979e0aac4e |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
845 | tag: tip |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
846 | parent: 1:579f120ba918 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
847 | user: test |
4899 | 848 | date: Thu Jan 01 00:00:00 1970 +0000 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
849 | instability: orphan |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
850 | summary: c_B0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
851 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
852 | o changeset: 3:d952d1794ff6 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
853 | | parent: 0:eba9c2249fe7 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
854 | | user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
855 | | date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
856 | | summary: c_A1 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
857 | | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
858 x | changeset: 1:579f120ba918 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
859 |/ user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
860 | date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
861 | obsolete: rewritten using amend as 3:d952d1794ff6 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
862 | summary: c_A0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
863 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
864 o changeset: 0:eba9c2249fe7 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
865 user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
866 date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
867 summary: c_ROOT |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
868 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
869 |
5801
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
870 $ hg rewind --hidden --to 'allpredecessors(desc("c_B0"))' --dry-run |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
871 abort: not rewinding, a65fceb2324a is a successor of 7e594302a05d |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
872 (pick only one of these changesets, possibly with --exact) |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
873 [255] |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
874 $ hg rewind --hidden --to 'allpredecessors(desc("c_B0"))' --dry-run --exact |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
875 abort: not rewinding, a65fceb2324a is a successor of 7e594302a05d |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
876 (pick only one of these changesets, possibly with --exact) |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
877 [255] |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
878 $ hg rewind --hidden --to 'allpredecessors(desc("c_B0"))' --dry-run --as-divergence |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
879 abort: not rewinding, a65fceb2324a is a successor of 7e594302a05d |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
880 (pick only one of these changesets, possibly with --exact) |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
881 [255] |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
882 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
883 Testing the defaults |
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
884 -------------------- |
3872
bbc3cfdfe42b
rewind: default to rewinding the current stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3871
diff
changeset
|
885 |
5536
9f9f04301df0
tests: less words and less markup to maintain in test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5450
diff
changeset
|
886 rewind with no arguments should be equivalent to `--from .` |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
887 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
888 $ echo 'default-date = 4 0' >> $HGRCPATH |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
889 $ hg rewind --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
890 rewinding ac979e0aac4e to 1 changesets: a65fceb2324a |
5447
ce56d29c3382
tests: actually test what the header promises to test
Anton Shestakov <av6@dwimlabs.net>
parents:
5446
diff
changeset
|
891 $ hg rewind |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
892 rewound to 1 changesets |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
893 (1 changesets obsoleted) |
4899 | 894 working directory is now at a5dd64adbb2a |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
895 $ hg log -G |
4899 | 896 @ changeset: 6:a5dd64adbb2a |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
897 | tag: tip |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
898 | parent: 3:d952d1794ff6 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
899 | user: test |
4899 | 900 | date: Thu Jan 01 00:00:00 1970 +0000 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
901 | summary: c_B0 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
902 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
903 o changeset: 3:d952d1794ff6 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
904 | parent: 0:eba9c2249fe7 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
905 | user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
906 | date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
907 | summary: c_A1 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
908 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
909 o changeset: 0:eba9c2249fe7 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
910 user: test |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
911 date: Thu Jan 01 00:00:00 1970 +0000 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
912 summary: c_ROOT |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
913 |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
914 $ hg debugobsolete |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
915 579f120ba91885449adc92eedf48ef3569742cee d952d1794ff657f5c2a82225d2e6307ed930b32f 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
916 7e594302a05d3769b27be88fc3cdfd39d7498498 a65fceb2324ae1eb1231610193d24a5fa02c7c0e 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '4', 'operation': 'evolve', 'user': 'test'} |
4899 | 917 7e594302a05d3769b27be88fc3cdfd39d7498498 ac979e0aac4e63ccbbf88ac33942192942302766 4 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
918 a65fceb2324ae1eb1231610193d24a5fa02c7c0e ac979e0aac4e63ccbbf88ac33942192942302766 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
919 a65fceb2324ae1eb1231610193d24a5fa02c7c0e a5dd64adbb2af2e646859b35d0d7128daa73cb2b 4 (Thu Jan 01 00:00:04 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
920 ac979e0aac4e63ccbbf88ac33942192942302766 a5dd64adbb2af2e646859b35d0d7128daa73cb2b 0 (Thu Jan 01 00:00:04 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
921 $ hg obslog --no-origin |
4899 | 922 @ a5dd64adbb2a (6) c_B0 |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
923 |\ |
4899 | 924 | x ac979e0aac4e (5) c_B0 |
925 |/| rewritten(meta, parent) as a5dd64adbb2a using rewind by test (Thu Jan 01 00:00:04 1970 +0000) | |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
926 | | |
4899 | 927 x | a65fceb2324a (4) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
928 |/ meta-changed(meta) as a5dd64adbb2a using rewind by test (Thu Jan 01 00:00:04 1970 +0000) |
4899 | 929 | rewritten(meta, parent) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
930 | |
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
931 x 7e594302a05d (2) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
932 rebased(parent) as a65fceb2324a using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
933 meta-changed(meta) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3867
339b05c3e929
rewind: add a test about rewinding top of stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3866
diff
changeset
|
934 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
935 Automatically rewinding the full stack (with --to) |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
936 -------------------------------------------------- |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
937 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
938 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
939 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
940 $ hg rewind --hidden --to 'predecessors(.)' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
941 rewinding d952d1794ff6 to 1 changesets: 579f120ba918 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
942 rewinding a5dd64adbb2a to 1 changesets: ac979e0aac4e |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
943 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
944 actual rewind |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
945 |
5446
5fc54b8f3f84
tests: move default-date manipulation closer to the commands that need it
Anton Shestakov <av6@dwimlabs.net>
parents:
5445
diff
changeset
|
946 $ echo 'default-date = 5 0' >> $HGRCPATH |
4624
c9798965b1f4
revset: switch internal uses and tests to `predecessors` from legacy name
Matt Harbison <matt_harbison@yahoo.com>
parents:
4576
diff
changeset
|
947 $ hg rewind --hidden --to 'predecessors(.)' |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
948 rewound to 2 changesets |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
949 (2 changesets obsoleted) |
4899 | 950 working directory is now at 3f2d8862657d |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
951 $ hg debugobsolete |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
952 579f120ba91885449adc92eedf48ef3569742cee d952d1794ff657f5c2a82225d2e6307ed930b32f 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
953 7e594302a05d3769b27be88fc3cdfd39d7498498 a65fceb2324ae1eb1231610193d24a5fa02c7c0e 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '4', 'operation': 'evolve', 'user': 'test'} |
4899 | 954 7e594302a05d3769b27be88fc3cdfd39d7498498 ac979e0aac4e63ccbbf88ac33942192942302766 4 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
955 a65fceb2324ae1eb1231610193d24a5fa02c7c0e ac979e0aac4e63ccbbf88ac33942192942302766 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
956 a65fceb2324ae1eb1231610193d24a5fa02c7c0e a5dd64adbb2af2e646859b35d0d7128daa73cb2b 4 (Thu Jan 01 00:00:04 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
957 ac979e0aac4e63ccbbf88ac33942192942302766 a5dd64adbb2af2e646859b35d0d7128daa73cb2b 0 (Thu Jan 01 00:00:04 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
958 579f120ba91885449adc92eedf48ef3569742cee 9c28b7ed3951fd15b20ab75449c1e0fdec445958 4 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
959 ac979e0aac4e63ccbbf88ac33942192942302766 3f2d8862657d20af331f0c0531f5228eef4d36c5 4 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
960 a5dd64adbb2af2e646859b35d0d7128daa73cb2b 3f2d8862657d20af331f0c0531f5228eef4d36c5 0 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
961 d952d1794ff657f5c2a82225d2e6307ed930b32f 9c28b7ed3951fd15b20ab75449c1e0fdec445958 0 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '11', 'operation': 'rewind', 'user': 'test'} | |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
962 $ hg obslog --no-origin |
4899 | 963 @ 3f2d8862657d (8) c_B0 |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
964 |\ |
4899 | 965 x | a5dd64adbb2a (6) c_B0 |
966 |\| rewritten(meta, parent) as 3f2d8862657d using rewind by test (Thu Jan 01 00:00:05 1970 +0000) | |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
967 | | |
4899 | 968 | x ac979e0aac4e (5) c_B0 |
969 |/| rewritten(meta, parent) as 3f2d8862657d using rewind by test (Thu Jan 01 00:00:05 1970 +0000) | |
970 | | rewritten(meta, parent) as a5dd64adbb2a using rewind by test (Thu Jan 01 00:00:04 1970 +0000) | |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
971 | | |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
972 x | a65fceb2324a (4) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
973 |/ meta-changed(meta) as a5dd64adbb2a using rewind by test (Thu Jan 01 00:00:04 1970 +0000) |
4899 | 974 | rewritten(meta, parent) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
975 | |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
976 x 7e594302a05d (2) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
977 rebased(parent) as a65fceb2324a using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
978 meta-changed(meta) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
979 |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
980 $ hg log -G |
4899 | 981 @ changeset: 8:3f2d8862657d |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
982 | tag: tip |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
983 | user: test |
4899 | 984 | date: Thu Jan 01 00:00:00 1970 +0000 |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
985 | summary: c_B0 |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
986 | |
4899 | 987 o changeset: 7:9c28b7ed3951 |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
988 | parent: 0:eba9c2249fe7 |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
989 | user: test |
4899 | 990 | date: Thu Jan 01 00:00:00 1970 +0000 |
3868
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
991 | summary: c_A0 |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
992 | |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
993 o changeset: 0:eba9c2249fe7 |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
994 user: test |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
995 date: Thu Jan 01 00:00:00 1970 +0000 |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
996 summary: c_ROOT |
1742254d1190
rewind: automatically rewind entire stack
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3867
diff
changeset
|
997 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
998 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
999 Automatically rewinding the full stack (with --from) |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1000 ---------------------------------------------------- |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1001 |
5544
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1002 target selection |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1003 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1004 $ hg rewind --from '.' --dry-run |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1005 rewinding 9c28b7ed3951 to 1 changesets: d952d1794ff6 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1006 rewinding 3f2d8862657d to 1 changesets: a5dd64adbb2a |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1007 |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1008 actual rewind |
0bb75a6c29b1
rewind: add a --dry-run flag
Anton Shestakov <av6@dwimlabs.net>
parents:
5536
diff
changeset
|
1009 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1010 $ echo 'default-date = 6 0' >> $HGRCPATH |
5450
64ff1b7c0481
tests: remove unnecessary command flags from test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5449
diff
changeset
|
1011 $ hg rewind --from '.' |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
1012 rewound to 2 changesets |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1013 (2 changesets obsoleted) |
4899 | 1014 working directory is now at d36d6d267714 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1015 $ hg debugobsolete |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1016 579f120ba91885449adc92eedf48ef3569742cee d952d1794ff657f5c2a82225d2e6307ed930b32f 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1017 7e594302a05d3769b27be88fc3cdfd39d7498498 a65fceb2324ae1eb1231610193d24a5fa02c7c0e 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '4', 'operation': 'evolve', 'user': 'test'} |
4899 | 1018 7e594302a05d3769b27be88fc3cdfd39d7498498 ac979e0aac4e63ccbbf88ac33942192942302766 4 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
1019 a65fceb2324ae1eb1231610193d24a5fa02c7c0e ac979e0aac4e63ccbbf88ac33942192942302766 0 (Thu Jan 01 00:00:03 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
1020 a65fceb2324ae1eb1231610193d24a5fa02c7c0e a5dd64adbb2af2e646859b35d0d7128daa73cb2b 4 (Thu Jan 01 00:00:04 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
1021 ac979e0aac4e63ccbbf88ac33942192942302766 a5dd64adbb2af2e646859b35d0d7128daa73cb2b 0 (Thu Jan 01 00:00:04 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
1022 579f120ba91885449adc92eedf48ef3569742cee 9c28b7ed3951fd15b20ab75449c1e0fdec445958 4 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
1023 ac979e0aac4e63ccbbf88ac33942192942302766 3f2d8862657d20af331f0c0531f5228eef4d36c5 4 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
1024 a5dd64adbb2af2e646859b35d0d7128daa73cb2b 3f2d8862657d20af331f0c0531f5228eef4d36c5 0 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
1025 d952d1794ff657f5c2a82225d2e6307ed930b32f 9c28b7ed3951fd15b20ab75449c1e0fdec445958 0 (Thu Jan 01 00:00:05 1970 +0000) {'ef1': '11', 'operation': 'rewind', 'user': 'test'} | |
1026 d952d1794ff657f5c2a82225d2e6307ed930b32f fef4355b4cc9e2d3ddc154f60e4f4f1a286e9ce7 4 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} | |
1027 a5dd64adbb2af2e646859b35d0d7128daa73cb2b d36d6d267714108384f31762b6193c32f9f97514 4 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
1028 3f2d8862657d20af331f0c0531f5228eef4d36c5 d36d6d267714108384f31762b6193c32f9f97514 0 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '6', 'operation': 'rewind', 'user': 'test'} | |
1029 9c28b7ed3951fd15b20ab75449c1e0fdec445958 fef4355b4cc9e2d3ddc154f60e4f4f1a286e9ce7 0 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '11', 'operation': 'rewind', 'user': 'test'} | |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1030 $ hg obslog --no-origin |
4899 | 1031 @ d36d6d267714 (10) c_B0 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1032 |\ |
4899 | 1033 x | 3f2d8862657d (8) c_B0 |
1034 |\| rewritten(meta, parent) as d36d6d267714 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) | |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1035 | | |
4899 | 1036 | x a5dd64adbb2a (6) c_B0 |
1037 |/| rewritten(meta, parent) as 3f2d8862657d using rewind by test (Thu Jan 01 00:00:05 1970 +0000) | |
1038 | | rewritten(meta, parent) as d36d6d267714 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) | |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1039 | | |
4899 | 1040 x | ac979e0aac4e (5) c_B0 |
1041 |\| rewritten(meta, parent) as 3f2d8862657d using rewind by test (Thu Jan 01 00:00:05 1970 +0000) | |
1042 | | rewritten(meta, parent) as a5dd64adbb2a using rewind by test (Thu Jan 01 00:00:04 1970 +0000) | |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1043 | | |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1044 | x a65fceb2324a (4) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
1045 |/ meta-changed(meta) as a5dd64adbb2a using rewind by test (Thu Jan 01 00:00:04 1970 +0000) |
4899 | 1046 | rewritten(meta, parent) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1047 | |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1048 x 7e594302a05d (2) c_B0 |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
1049 rebased(parent) as a65fceb2324a using evolve by test (Thu Jan 01 00:00:03 1970 +0000) |
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
1050 meta-changed(meta) as ac979e0aac4e using rewind by test (Thu Jan 01 00:00:03 1970 +0000) |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1051 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1052 $ hg log -G |
4899 | 1053 @ changeset: 10:d36d6d267714 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1054 | tag: tip |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1055 | user: test |
4899 | 1056 | date: Thu Jan 01 00:00:00 1970 +0000 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1057 | summary: c_B0 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1058 | |
4899 | 1059 o changeset: 9:fef4355b4cc9 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1060 | parent: 0:eba9c2249fe7 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1061 | user: test |
4899 | 1062 | date: Thu Jan 01 00:00:00 1970 +0000 |
3871
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1063 | summary: c_A1 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1064 | |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1065 o changeset: 0:eba9c2249fe7 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1066 user: test |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1067 date: Thu Jan 01 00:00:00 1970 +0000 |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1068 summary: c_ROOT |
2e32a1ef0c60
rewing: add the ability to rewind "from" revisions
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3870
diff
changeset
|
1069 |
3873
b81fd1487e04
rewing: prevent rewind in case of uncommitted changes
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3872
diff
changeset
|
1070 $ cd .. |
b81fd1487e04
rewing: prevent rewind in case of uncommitted changes
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3872
diff
changeset
|
1071 |
4820
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1072 Merge commits |
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1073 ============= |
3873
b81fd1487e04
rewing: prevent rewind in case of uncommitted changes
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
3872
diff
changeset
|
1074 |
4820
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1075 $ hg clone -q rewind-testing-base rewind-merge |
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1076 $ cd rewind-merge |
4722
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1077 |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1078 $ hg up --clean .^ |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1079 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1080 $ echo foo > foo |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1081 $ hg ci -qAm foo |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1082 |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1083 $ hg merge |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1084 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1085 (branch merge, don't forget to commit) |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1086 $ hg ci -m merge |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1087 $ hg st --change . |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1088 A B |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1089 |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1090 $ echo bar > foo |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1091 $ hg amend -m 'merge, but foo is now bar' |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1092 $ hg st --change . |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1093 M foo |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1094 A B |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1095 |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1096 $ hg rewind --from . |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
1097 rewound to 1 changesets |
4722
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1098 (1 changesets obsoleted) |
4820
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1099 working directory is now at 9d325190bd87 |
4722
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1100 $ hg st --change . |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1101 A B |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1102 |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1103 $ hg glf -r '. + allpredecessors(.) + parents(.)' --hidden |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1104 @ 6: merge () |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1105 |\ |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1106 +---x 5: merge, but foo is now bar (foo) |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1107 | |/ |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1108 +---x 4: merge () |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1109 | |/ |
4820
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1110 | o 3: foo (foo) |
4722
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1111 | | |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1112 | ~ |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1113 o 2: c_B0 (B) |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1114 | |
7839720c7c75
rewind: make sure merge commits include files from p1 and p2
Anton Shestakov <av6@dwimlabs.net>
parents:
4712
diff
changeset
|
1115 ~ |
4820
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1116 |
d842a4c6fc4a
tests: separate rewinding of merge commits, temporarily drop an error case
Anton Shestakov <av6@dwimlabs.net>
parents:
4722
diff
changeset
|
1117 $ cd .. |
4821
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1118 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1119 Rewind --keep |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1120 ============= |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1121 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1122 $ hg init rewind-keep |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1123 $ cd rewind-keep |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1124 $ echo root > root |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1125 $ hg ci -qAm 'root' |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1126 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1127 $ echo apple > a |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1128 $ echo banana > b |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1129 $ hg ci -qAm initial |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1130 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1131 $ hg rm b |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1132 $ echo apricot > a |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1133 $ echo coconut > c |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1134 $ hg add c |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1135 $ hg status |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1136 M a |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1137 A c |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1138 R b |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1139 $ hg amend -m amended |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1140 $ hg glf --hidden |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1141 @ 2: amended (a c) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1142 | |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1143 | x 1: initial (a b) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1144 |/ |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1145 o 0: root (root) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1146 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1147 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1148 Clean wdir |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1149 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1150 $ hg rewind --keep --to 'desc("initial")' --hidden |
5445
d0b0ef0ba094
rewind: past tense of rewind is rewound
Anton Shestakov <av6@dwimlabs.net>
parents:
5301
diff
changeset
|
1151 rewound to 1 changesets |
4821
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1152 (1 changesets obsoleted) |
5275
417503ef667d
tests: add debugobsolete calls before many obslog calls
Martin von Zweigbergk <martinvonz@google.com>
parents:
5123
diff
changeset
|
1153 $ hg debugobsolete |
417503ef667d
tests: add debugobsolete calls before many obslog calls
Martin von Zweigbergk <martinvonz@google.com>
parents:
5123
diff
changeset
|
1154 30704102d912d9d35a3d51400c4c93ad1e8bc7f3 2ea5be2f87510c7d26d5866dec83b57a7d939c4a 0 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} |
417503ef667d
tests: add debugobsolete calls before many obslog calls
Martin von Zweigbergk <martinvonz@google.com>
parents:
5123
diff
changeset
|
1155 30704102d912d9d35a3d51400c4c93ad1e8bc7f3 b4c97fddc16aa57693fa0a730d4b44ceb75bb35c 4 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
417503ef667d
tests: add debugobsolete calls before many obslog calls
Martin von Zweigbergk <martinvonz@google.com>
parents:
5123
diff
changeset
|
1156 2ea5be2f87510c7d26d5866dec83b57a7d939c4a b4c97fddc16aa57693fa0a730d4b44ceb75bb35c 0 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '11', 'operation': 'rewind', 'user': 'test'} |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1157 $ hg obslog --no-origin |
4821
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1158 @ b4c97fddc16a (3) initial |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1159 |\ |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1160 x | 2ea5be2f8751 (2) amended |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1161 |/ rewritten(description, meta, content) as b4c97fddc16a using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1162 | |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1163 x 30704102d912 (1) initial |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1164 rewritten(description, content) as 2ea5be2f8751 using amend by test (Thu Jan 01 00:00:06 1970 +0000) |
5123
900668a93629
obslog: use _successorsetverb() in regular obslog too
Anton Shestakov <av6@dwimlabs.net>
parents:
4899
diff
changeset
|
1165 meta-changed(meta) as b4c97fddc16a using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
4821
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1166 |
5301
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1167 $ hg obslog |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1168 @ b4c97fddc16a (3) initial |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1169 |\ rewritten(description, meta, content) from 2ea5be2f8751 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1170 | | meta-changed(meta) from 30704102d912 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1171 | | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1172 x | 2ea5be2f8751 (2) amended |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1173 |/ rewritten(description, content) from 30704102d912 using amend by test (Thu Jan 01 00:00:06 1970 +0000) |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1174 | |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1175 x 30704102d912 (1) initial |
e8660b28bfee
obslog: makes --origin flag the default
Anton Shestakov <av6@dwimlabs.net>
parents:
5275
diff
changeset
|
1176 |
4821
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1177 $ hg glf --hidden |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1178 @ 3: initial (a b) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1179 | |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1180 | x 2: amended (a c) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1181 |/ |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1182 | x 1: initial (a b) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1183 |/ |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1184 o 0: root (root) |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1185 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1186 $ hg st |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1187 M a |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1188 A c |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1189 R b |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1190 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1191 Making wdir even more dirty |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1192 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1193 $ echo avocado > a |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1194 $ echo durian > d |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1195 $ hg st |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1196 M a |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1197 A c |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1198 R b |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1199 ? d |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1200 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1201 No rewinding without --keep |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1202 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1203 $ hg rewind --to 'desc("amended")' --hidden |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1204 abort: uncommitted changes |
5666
e5d91fd1f319
tests: update with more detailed exit codes
Martin von Zweigbergk <martinvonz@google.com>
parents:
5599
diff
changeset
|
1205 [20] |
4821
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1206 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1207 XXX: Unfortunately, even with --keep it's not allowed |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1208 |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1209 $ hg rewind --keep --to 'desc("amended")' --hidden |
d8e36e60aea0
rewind: add --keep flag that "doesn't modify working directory"
Anton Shestakov <av6@dwimlabs.net>
parents:
4820
diff
changeset
|
1210 abort: uncommitted changes |
5666
e5d91fd1f319
tests: update with more detailed exit codes
Martin von Zweigbergk <martinvonz@google.com>
parents:
5599
diff
changeset
|
1211 [20] |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1212 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1213 $ cd .. |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1214 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1215 Extra cases related to folds |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1216 ============================ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1217 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1218 folding with a changeset created after the rewind target |
5803
abbc021c6f68
tests: add underlines to test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5802
diff
changeset
|
1219 -------------------------------------------------------- |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1220 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1221 .. B0 ⇠\ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1222 .. | ⇠AB2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1223 .. A0 ⇠A1 ⇠/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1224 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1225 this simple test case introduces the idea of making rewind consider different |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1226 evolutions of fold components: "parent" evolution of A has more predecessors |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1227 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1228 $ hg init extra-fold-case-1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1229 $ cd extra-fold-case-1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1230 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1231 $ echo R > R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1232 $ hg ci -qAm R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1233 $ echo A > A |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1234 $ hg ci -qAm A0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1235 $ hg amend -m A1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1236 $ echo B > B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1237 $ hg ci -qAm B0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1238 $ hg fold -r 'desc("A1")::' -m AB2 --exact -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1239 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1240 $ hg glhf --hidden |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1241 @ 4:7f9a5314ef94 AB2 (A B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1242 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1243 | x 3:16429ed4b6cb B0 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1244 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1245 | x 2:3748b241cad8 A1 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1246 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1247 | x 1:fa8956746c52 A0 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1248 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1249 o 0:167e04d3d1b2 R (R) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1250 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1251 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1252 target selection |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1253 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1254 when rewinding from a fold, rewind to all of its components (at various points |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1255 in their evolution) to not lose work |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1256 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1257 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1258 rewinding 7f9a5314ef94 to 2 changesets: fa8956746c52 16429ed4b6cb |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1259 $ hg rewind --hidden --to 'desc("B0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1260 rewinding 7f9a5314ef94 to 2 changesets: 3748b241cad8 16429ed4b6cb |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1261 $ hg rewind --from 'desc("AB2")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1262 rewinding 7f9a5314ef94 to 2 changesets: 3748b241cad8 16429ed4b6cb |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1263 |
5801
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
1264 $ hg rewind --hidden --to 'allpredecessors(desc("AB2"))' --dry-run |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
1265 abort: not rewinding, 3748b241cad8 is a successor of fa8956746c52 |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
1266 (pick only one of these changesets, possibly with --exact) |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
1267 [255] |
e8a43f5929f6
rewind: abort when trying to rewind to multiple unrelated predecessors
Anton Shestakov <av6@dwimlabs.net>
parents:
5800
diff
changeset
|
1268 |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1269 $ cd .. |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1270 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1271 folding with a changeset we rebased onto |
5803
abbc021c6f68
tests: add underlines to test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5802
diff
changeset
|
1272 ---------------------------------------- |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1273 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1274 .. A0 ⇠A1 ⇠\ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1275 .. | ⇠AB2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1276 .. B0 ⇠/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1277 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1278 similar to the previous case, but this time evolution of A has more |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1279 predecessors and at some point starts to be based on B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1280 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1281 $ hg init extra-fold-case-2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1282 $ cd extra-fold-case-2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1283 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1284 $ echo R > R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1285 $ hg ci -qAm R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1286 $ echo A > A |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1287 $ hg ci -qAm A0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1288 $ hg up 'desc("R")' -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1289 $ echo B > B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1290 $ hg ci -qAm B0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1291 $ echo A > A |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1292 $ hg ci -qAm A1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1293 $ hg prune -r 'desc("A0")' -s 'desc("A1")' |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1294 1 changesets pruned |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1295 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1296 $ hg fold -r 'desc("B0")::' -m AB2 --exact -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1297 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1298 $ hg glhf --hidden |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1299 @ 4:1988e9fe9517 AB2 (A B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1300 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1301 | x 3:7175ff74409b A1 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1302 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1303 | x 2:d6ed1d624918 B0 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1304 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1305 | x 1:fa8956746c52 A0 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1306 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1307 o 0:167e04d3d1b2 R (R) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1308 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1309 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1310 target selection |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1311 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1312 when rewinding from a fold, rewind to all of its components (at various points |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1313 in their evolution) to not lose work |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1314 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1315 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1316 rewinding 1988e9fe9517 to 2 changesets: fa8956746c52 d6ed1d624918 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1317 $ hg rewind --hidden --to 'desc("B0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1318 rewinding 1988e9fe9517 to 2 changesets: d6ed1d624918 7175ff74409b |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1319 $ hg rewind --from 'desc("AB2")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1320 rewinding 1988e9fe9517 to 2 changesets: d6ed1d624918 7175ff74409b |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1321 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1322 $ cd .. |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1323 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1324 folding with a changeset that rebased on us |
5803
abbc021c6f68
tests: add underlines to test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5802
diff
changeset
|
1325 ------------------------------------------- |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1326 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1327 .. B0 ⇠⇠⇠⇠B1 ⇠\ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1328 .. | | ⇠AB2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1329 .. | A0 ⇠A1 ⇠/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1330 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1331 now evolutions of A and B have the same amount of changesets, but at point 0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1332 they aren't yet related |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1333 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1334 $ hg init extra-fold-case-3 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1335 $ cd extra-fold-case-3 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1336 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1337 $ echo R > R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1338 $ hg ci -qAm R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1339 $ echo A > A |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1340 $ hg ci -qAm A0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1341 $ hg amend -m A1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1342 $ hg up 'desc("R")' -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1343 $ echo B > B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1344 $ hg ci -qAm B0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1345 $ hg up 'desc("A1")' -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1346 $ echo B > B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1347 $ hg ci -qAm B1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1348 $ hg prune -r 'desc("B0")' -s 'desc("B1")' |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1349 1 changesets pruned |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1350 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1351 $ hg fold -r 'desc("A1")::' -m AB2 --exact -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1352 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1353 $ hg glhf --hidden |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1354 @ 5:7f9a5314ef94 AB2 (A B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1355 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1356 | x 4:fe7a7d317e16 B1 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1357 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1358 +---x 3:d6ed1d624918 B0 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1359 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1360 | x 2:3748b241cad8 A1 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1361 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1362 | x 1:fa8956746c52 A0 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1363 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1364 o 0:167e04d3d1b2 R (R) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1365 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1366 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1367 target selection |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1368 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1369 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1370 rewinding 7f9a5314ef94 to 2 changesets: fa8956746c52 fe7a7d317e16 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1371 $ hg rewind --hidden --to 'desc("B0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1372 rewinding 7f9a5314ef94 to 2 changesets: 3748b241cad8 d6ed1d624918 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1373 $ hg rewind --hidden --to 'desc("A1")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1374 rewinding 7f9a5314ef94 to 2 changesets: 3748b241cad8 fe7a7d317e16 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1375 $ hg rewind --hidden --to 'desc("B1")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1376 rewinding 7f9a5314ef94 to 2 changesets: 3748b241cad8 fe7a7d317e16 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1377 $ hg rewind --from 'desc("AB2")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1378 rewinding 7f9a5314ef94 to 2 changesets: 3748b241cad8 fe7a7d317e16 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1379 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1380 actual rewind |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1381 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1382 $ hg rewind --hidden --to 'desc("A0")' |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1383 1 new orphan changesets |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1384 rewound to 2 changesets |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1385 (1 changesets obsoleted) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1386 working directory is now at e492d2f9be46 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1387 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1388 after rewind to A0: |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1389 - A0' and B1' are successors to AB2 (split using rewind) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1390 - A0' is a successor of A0 (operation: rewind) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1391 - A0' is a child of R (just like A0) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1392 - B1' is a successor of B1 (operation: rewind) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1393 - B1' is a child of A1 (just like B1), and therefore an orphan |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1394 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1395 $ hg obslog -a |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1396 o 54b340ce1d87 (6) A0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1397 |\ split(description, meta, parent, content) from 7f9a5314ef94 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1398 | | meta-changed(meta) from fa8956746c52 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1399 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1400 +---@ e492d2f9be46 (7) B1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1401 | | | split(description, meta, parent, content) from 7f9a5314ef94 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1402 | | | meta-changed(meta) from fe7a7d317e16 using rewind by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1403 | | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1404 x---+ 7f9a5314ef94 (5) AB2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1405 | | | folded(description, parent, content) from 3748b241cad8, fe7a7d317e16 using fold by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1406 | | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1407 x | | 3748b241cad8 (2) A1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1408 |/ / reworded(description) from fa8956746c52 using amend by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1409 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1410 | x fe7a7d317e16 (4) B1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1411 | | rewritten(description, parent) from d6ed1d624918 using prune by test (Thu Jan 01 00:00:06 1970 +0000) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1412 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1413 | x d6ed1d624918 (3) B0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1414 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1415 x fa8956746c52 (1) A0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1416 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1417 $ hg glhf |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1418 @ 7:e492d2f9be46 B1 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1419 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1420 | o 6:54b340ce1d87 A0 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1421 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1422 x | 2:3748b241cad8 A1 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1423 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1424 o 0:167e04d3d1b2 R (R) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1425 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1426 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1427 $ hg debugobsolete --exclusive -r 'first(head())' |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1428 7f9a5314ef94f5856ee90661268194cc5ce9b332 54b340ce1d87f3593fd9de2a742e7b444e5136ed e492d2f9be46b73c0cfa51709e92db864b8f3ed9 0 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '15', 'operation': 'rewind', 'user': 'test'} |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1429 fa8956746c5294ce3351309133b450c5930f30f5 54b340ce1d87f3593fd9de2a742e7b444e5136ed 4 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1430 $ hg debugobsolete --exclusive -r 'last(head())' |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1431 7f9a5314ef94f5856ee90661268194cc5ce9b332 54b340ce1d87f3593fd9de2a742e7b444e5136ed e492d2f9be46b73c0cfa51709e92db864b8f3ed9 0 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '15', 'operation': 'rewind', 'user': 'test'} |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1432 fe7a7d317e168a15e8aa43131b54d3256443d728 e492d2f9be46b73c0cfa51709e92db864b8f3ed9 4 (Thu Jan 01 00:00:06 1970 +0000) {'ef1': '2', 'operation': 'rewind', 'user': 'test'} |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1433 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1434 $ cd .. |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1435 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1436 simple fold with a missing part |
5803
abbc021c6f68
tests: add underlines to test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5802
diff
changeset
|
1437 ------------------------------- |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1438 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1439 .. B0 ⇠(B1) ⇠\ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1440 .. | | ⇠AB2 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1441 .. A0 ⇠A1 ⇠/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1442 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1443 a stack was rewritten, but then a part of it became unknown locally |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1444 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1445 $ hg init extra-fold-case-4 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1446 $ cd extra-fold-case-4 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1447 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1448 $ echo R > R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1449 $ hg ci -qAm R |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1450 $ echo A > A |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1451 $ hg ci -qAm A0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1452 $ echo B > B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1453 $ hg ci -qAm B0 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1454 $ hg up 'desc("R")' -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1455 $ echo A > A |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1456 $ hg ci -qAm A1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1457 $ echo B > B |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1458 $ hg ci -qAm B1 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1459 $ hg prune -r 'desc("A0")+desc("B0")' -s 'desc("A1")+desc("B1")' --biject |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1460 2 changesets pruned |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1461 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1462 $ hg fold -r 'desc("A1") + desc("B1")' -m AB2 --exact -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1463 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1464 $ hg glhf --hidden |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1465 @ 5:1988e9fe9517 AB2 (A B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1466 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1467 | x 4:25210d726f52 B1 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1468 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1469 | x 3:9c76368ab336 A1 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1470 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1471 | x 2:a07c12c45197 B0 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1472 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1473 | x 1:fa8956746c52 A0 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1474 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1475 o 0:167e04d3d1b2 R (R) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1476 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1477 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1478 target selection |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1479 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1480 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1481 rewinding 1988e9fe9517 to 2 changesets: fa8956746c52 25210d726f52 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1482 $ hg rewind --hidden --to 'desc("A1")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1483 rewinding 1988e9fe9517 to 2 changesets: 9c76368ab336 25210d726f52 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1484 $ hg rewind --hidden --to 'desc("B1")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1485 rewinding 1988e9fe9517 to 2 changesets: 9c76368ab336 25210d726f52 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1486 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1487 because B0 is a child of A0, we use A0 instead of A1 unless --exact is given |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1488 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1489 XXX the semantic of --exact might need clarification here, |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1490 XXX for example, shouln't --exact make sure we only rewind to the `--to` target ? |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1491 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1492 $ hg rewind --hidden --to 'desc("B0")' --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1493 rewinding 1988e9fe9517 to 2 changesets: fa8956746c52 a07c12c45197 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1494 $ hg rewind --hidden --to 'desc("B0")' --exact --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1495 rewinding 1988e9fe9517 to 2 changesets: a07c12c45197 9c76368ab336 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1496 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1497 stripping one of the fold parts |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1498 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1499 $ hg strip --config extensions.strip= -r 'desc("B1")' --hidden -q |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1500 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1501 $ hg glhf --hidden |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1502 @ 4:1988e9fe9517 AB2 (A B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1503 | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1504 | x 3:9c76368ab336 A1 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1505 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1506 | x 2:a07c12c45197 B0 (B) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1507 | | |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1508 | x 1:fa8956746c52 A0 (A) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1509 |/ |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1510 o 0:167e04d3d1b2 R (R) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1511 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1512 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1513 target selection |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1514 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1515 the obvious challenge here is to somehow work around the missing fold |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1516 component, but we can't do much because it is one of the latest predecessors of |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1517 AB2 fold |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1518 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1519 in future we might have a way to allow rewind to skip changesets unknown |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1520 locally and still proceed (and lose the least amount of work possible) |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1521 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1522 $ hg rewind --hidden --to 'desc("A0")+desc("B0")' --exact --dry-run |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1523 rewinding 1988e9fe9517 to 2 changesets: fa8956746c52 a07c12c45197 |
5802
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1524 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1525 abort: not rewinding, some predecessors are unknown locally: 25210d726f52 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1526 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1527 [255] |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1528 $ hg rewind --hidden --to 'desc("A1")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1529 abort: not rewinding, some predecessors are unknown locally: 25210d726f52 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1530 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1531 [255] |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1532 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1533 XXX the semantic of --exact might need clarification here, |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1534 XXX for example, shouln't --exact make sure we only rewind to the `--to` target ? |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1535 |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1536 $ hg rewind --hidden --to 'desc("A1")' --exact --dry-run |
5802
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1537 abort: not rewinding, some predecessors are unknown locally: 25210d726f52 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1538 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1539 [255] |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1540 $ hg rewind --from 'desc("AB2")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1541 abort: not rewinding, some predecessors are unknown locally: 25210d726f52 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1542 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1543 [255] |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1544 $ hg rewind --from 'desc("AB2")' --exact --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1545 abort: not rewinding, some predecessors are unknown locally: 25210d726f52 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1546 (try selecting all changesets to rewind to manually, possibly with --exact) |
5800
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1547 [255] |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1548 |
668817e8c007
rewind: walk obsmarkers and add more targets to rewind to
Anton Shestakov <av6@dwimlabs.net>
parents:
5666
diff
changeset
|
1549 $ cd .. |
5802
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1550 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1551 split and then fold with a missing part |
5803
abbc021c6f68
tests: add underlines to test-rewind.t
Anton Shestakov <av6@dwimlabs.net>
parents:
5802
diff
changeset
|
1552 --------------------------------------- |
5802
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1553 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1554 .. /⇠(C1) ⇠\ |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1555 .. BC0 ⇠| \ |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1556 .. | \⇠B1 ⇠AC2 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1557 .. A0 ⇠⇠⇠⇠⇠⇠⇠⇠⇠⇠⇠/ |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1558 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1559 here we have a case when walking successors and then predecessors of target |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1560 revisions just once might not be enough, because it's a more complex DAG with a |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1561 changeset missing from local repo |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1562 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1563 $ hg init extra-fold-case-5 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1564 $ cd extra-fold-case-5 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1565 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1566 $ echo R > R |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1567 $ hg ci -qAm R |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1568 $ echo A > A |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1569 $ hg ci -qAm A0 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1570 $ echo B > B |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1571 $ echo C > C |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1572 $ hg ci -qAm BC0 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1573 $ hg up 'desc("A0")' -q |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1574 $ echo B > B |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1575 $ hg ci -qAm B1 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1576 $ echo C > C |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1577 $ hg ci -qAm C1 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1578 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1579 $ hg prune -r 'desc("BC0")' -s 'desc("B1")+desc("C1")' --split |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1580 1 changesets pruned |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1581 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1582 $ hg up 'desc("R")' -q |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1583 $ echo A > A |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1584 $ echo C > C |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1585 $ hg ci -qAm AC2 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1586 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1587 $ hg prune -r 'desc("A0")+desc("C1")' -s 'desc("AC2")' --fold |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1588 2 changesets pruned |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1589 1 new orphan changesets |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1590 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1591 $ hg glhf --hidden |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1592 @ 5:9ccaac2e5fbb AC2 (A C) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1593 | |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1594 | x 4:2e4ab803d8ae C1 (C) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1595 | | |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1596 | * 3:44774eafdc1c B1 (B) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1597 | | |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1598 | | x 2:883d75400657 BC0 (B C) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1599 | |/ |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1600 | x 1:fa8956746c52 A0 (A) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1601 |/ |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1602 o 0:167e04d3d1b2 R (R) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1603 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1604 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1605 target selection |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1606 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1607 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1608 rewinding 9ccaac2e5fbb to 2 changesets: fa8956746c52 2e4ab803d8ae |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1609 $ hg rewind --hidden --to 'desc("BC0")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1610 rewinding 44774eafdc1c to 1 changesets: 883d75400657 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1611 rewinding 9ccaac2e5fbb to 2 changesets: fa8956746c52 883d75400657 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1612 $ hg rewind --from 'desc("AC2")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1613 rewinding 9ccaac2e5fbb to 2 changesets: fa8956746c52 2e4ab803d8ae |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1614 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1615 stripping a component of AC2 fold |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1616 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1617 $ hg strip --config extensions.strip= --hidden -r 'desc("C1")' -q |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1618 warning: ignoring unknown working parent 9ccaac2e5fbb! |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1619 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1620 target selection |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1621 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1622 at the moment, there's not much that we can do here because of missing C1 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1623 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1624 in future we might have a way to allow rewind to skip changesets unknown |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1625 locally and still proceed (and lose the least amount of work possible) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1626 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1627 XXX the semantic of --exact might need clarification here, |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1628 XXX for example, shouln't --exact make sure we only rewind to the `--to` target ? |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1629 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1630 $ hg rewind --hidden --to 'desc("A0")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1631 abort: not rewinding, some predecessors are unknown locally: 2e4ab803d8ae |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1632 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1633 [255] |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1634 $ hg rewind --hidden --to 'desc("BC0")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1635 rewinding 44774eafdc1c to 1 changesets: 883d75400657 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1636 rewinding 9ccaac2e5fbb to 2 changesets: fa8956746c52 883d75400657 |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1637 $ hg rewind --from 'desc("AC2")' --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1638 abort: not rewinding, some predecessors are unknown locally: 2e4ab803d8ae |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1639 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1640 [255] |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1641 $ hg rewind --from 'desc("AC2")' --exact --dry-run |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1642 abort: not rewinding, some predecessors are unknown locally: 2e4ab803d8ae |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1643 (try selecting all changesets to rewind to manually, possibly with --exact) |
84efc2e92228
rewind: abort if some parts of a fold are unknown locally
Anton Shestakov <av6@dwimlabs.net>
parents:
5801
diff
changeset
|
1644 [255] |