##// END OF EJS Templates
test: add a test for stabilization related labels...
Boris Feld -
r33775:2415ad74 default
parent child Browse files
Show More
@@ -1,1472 +1,1506 b''
1 $ cat >> $HGRCPATH << EOF
1 $ cat >> $HGRCPATH << EOF
2 > [phases]
2 > [phases]
3 > # public changeset are not obsolete
3 > # public changeset are not obsolete
4 > publish=false
4 > publish=false
5 > [ui]
5 > [ui]
6 > logtemplate="{rev}:{node|short} ({phase}{if(obsolete, ' *{obsolete}*')}{if(instabilities, ' {instabilities}')}) [{tags} {bookmarks}] {desc|firstline}\n"
6 > logtemplate="{rev}:{node|short} ({phase}{if(obsolete, ' *{obsolete}*')}{if(instabilities, ' {instabilities}')}) [{tags} {bookmarks}] {desc|firstline}\n"
7 > EOF
7 > EOF
8 $ mkcommit() {
8 $ mkcommit() {
9 > echo "$1" > "$1"
9 > echo "$1" > "$1"
10 > hg add "$1"
10 > hg add "$1"
11 > hg ci -m "add $1"
11 > hg ci -m "add $1"
12 > }
12 > }
13 $ getid() {
13 $ getid() {
14 > hg log -T "{node}\n" --hidden -r "desc('$1')"
14 > hg log -T "{node}\n" --hidden -r "desc('$1')"
15 > }
15 > }
16
16
17 $ cat > debugkeys.py <<EOF
17 $ cat > debugkeys.py <<EOF
18 > def reposetup(ui, repo):
18 > def reposetup(ui, repo):
19 > class debugkeysrepo(repo.__class__):
19 > class debugkeysrepo(repo.__class__):
20 > def listkeys(self, namespace):
20 > def listkeys(self, namespace):
21 > ui.write('listkeys %s\n' % (namespace,))
21 > ui.write('listkeys %s\n' % (namespace,))
22 > return super(debugkeysrepo, self).listkeys(namespace)
22 > return super(debugkeysrepo, self).listkeys(namespace)
23 >
23 >
24 > if repo.local():
24 > if repo.local():
25 > repo.__class__ = debugkeysrepo
25 > repo.__class__ = debugkeysrepo
26 > EOF
26 > EOF
27
27
28 $ hg init tmpa
28 $ hg init tmpa
29 $ cd tmpa
29 $ cd tmpa
30 $ mkcommit kill_me
30 $ mkcommit kill_me
31
31
32 Checking that the feature is properly disabled
32 Checking that the feature is properly disabled
33
33
34 $ hg debugobsolete -d '0 0' `getid kill_me` -u babar
34 $ hg debugobsolete -d '0 0' `getid kill_me` -u babar
35 abort: creating obsolete markers is not enabled on this repo
35 abort: creating obsolete markers is not enabled on this repo
36 [255]
36 [255]
37
37
38 Enabling it
38 Enabling it
39
39
40 $ cat >> $HGRCPATH << EOF
40 $ cat >> $HGRCPATH << EOF
41 > [experimental]
41 > [experimental]
42 > stabilization=createmarkers,exchange
42 > stabilization=createmarkers,exchange
43 > EOF
43 > EOF
44
44
45 Killing a single changeset without replacement
45 Killing a single changeset without replacement
46
46
47 $ hg debugobsolete 0
47 $ hg debugobsolete 0
48 abort: changeset references must be full hexadecimal node identifiers
48 abort: changeset references must be full hexadecimal node identifiers
49 [255]
49 [255]
50 $ hg debugobsolete '00'
50 $ hg debugobsolete '00'
51 abort: changeset references must be full hexadecimal node identifiers
51 abort: changeset references must be full hexadecimal node identifiers
52 [255]
52 [255]
53 $ hg debugobsolete -d '0 0' `getid kill_me` -u babar
53 $ hg debugobsolete -d '0 0' `getid kill_me` -u babar
54 obsoleted 1 changesets
54 obsoleted 1 changesets
55 $ hg debugobsolete
55 $ hg debugobsolete
56 97b7c2d76b1845ed3eb988cd612611e72406cef0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'babar'}
56 97b7c2d76b1845ed3eb988cd612611e72406cef0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'babar'}
57
57
58 (test that mercurial is not confused)
58 (test that mercurial is not confused)
59
59
60 $ hg up null --quiet # having 0 as parent prevents it to be hidden
60 $ hg up null --quiet # having 0 as parent prevents it to be hidden
61 $ hg tip
61 $ hg tip
62 -1:000000000000 (public) [tip ]
62 -1:000000000000 (public) [tip ]
63 $ hg up --hidden tip --quiet
63 $ hg up --hidden tip --quiet
64
64
65 Killing a single changeset with itself should fail
65 Killing a single changeset with itself should fail
66 (simple local safeguard)
66 (simple local safeguard)
67
67
68 $ hg debugobsolete `getid kill_me` `getid kill_me`
68 $ hg debugobsolete `getid kill_me` `getid kill_me`
69 abort: bad obsmarker input: in-marker cycle with 97b7c2d76b1845ed3eb988cd612611e72406cef0
69 abort: bad obsmarker input: in-marker cycle with 97b7c2d76b1845ed3eb988cd612611e72406cef0
70 [255]
70 [255]
71
71
72 $ cd ..
72 $ cd ..
73
73
74 Killing a single changeset with replacement
74 Killing a single changeset with replacement
75 (and testing the format option)
75 (and testing the format option)
76
76
77 $ hg init tmpb
77 $ hg init tmpb
78 $ cd tmpb
78 $ cd tmpb
79 $ mkcommit a
79 $ mkcommit a
80 $ mkcommit b
80 $ mkcommit b
81 $ mkcommit original_c
81 $ mkcommit original_c
82 $ hg up "desc('b')"
82 $ hg up "desc('b')"
83 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
83 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
84 $ mkcommit new_c
84 $ mkcommit new_c
85 created new head
85 created new head
86 $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden
86 $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden
87 $ hg debugobsolete --config format.obsstore-version=0 --flag 12 `getid original_c` `getid new_c` -d '121 120'
87 $ hg debugobsolete --config format.obsstore-version=0 --flag 12 `getid original_c` `getid new_c` -d '121 120'
88 obsoleted 1 changesets
88 obsoleted 1 changesets
89 $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden
89 $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden
90 2:245bde4270cd add original_c
90 2:245bde4270cd add original_c
91 $ hg debugrevlog -cd
91 $ hg debugrevlog -cd
92 # rev p1rev p2rev start end deltastart base p1 p2 rawsize totalsize compression heads chainlen
92 # rev p1rev p2rev start end deltastart base p1 p2 rawsize totalsize compression heads chainlen
93 0 -1 -1 0 59 0 0 0 0 58 58 0 1 0
93 0 -1 -1 0 59 0 0 0 0 58 58 0 1 0
94 1 0 -1 59 118 59 59 0 0 58 116 0 1 0
94 1 0 -1 59 118 59 59 0 0 58 116 0 1 0
95 2 1 -1 118 193 118 118 59 0 76 192 0 1 0
95 2 1 -1 118 193 118 118 59 0 76 192 0 1 0
96 3 1 -1 193 260 193 193 59 0 66 258 0 2 0
96 3 1 -1 193 260 193 193 59 0 66 258 0 2 0
97 $ hg debugobsolete
97 $ hg debugobsolete
98 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
98 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
99
99
100 (check for version number of the obsstore)
100 (check for version number of the obsstore)
101
101
102 $ dd bs=1 count=1 if=.hg/store/obsstore 2>/dev/null
102 $ dd bs=1 count=1 if=.hg/store/obsstore 2>/dev/null
103 \x00 (no-eol) (esc)
103 \x00 (no-eol) (esc)
104
104
105 do it again (it read the obsstore before adding new changeset)
105 do it again (it read the obsstore before adding new changeset)
106
106
107 $ hg up '.^'
107 $ hg up '.^'
108 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
108 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
109 $ mkcommit new_2_c
109 $ mkcommit new_2_c
110 created new head
110 created new head
111 $ hg debugobsolete -d '1337 0' `getid new_c` `getid new_2_c`
111 $ hg debugobsolete -d '1337 0' `getid new_c` `getid new_2_c`
112 obsoleted 1 changesets
112 obsoleted 1 changesets
113 $ hg debugobsolete
113 $ hg debugobsolete
114 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
114 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
115 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
115 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
116
116
117 Register two markers with a missing node
117 Register two markers with a missing node
118
118
119 $ hg up '.^'
119 $ hg up '.^'
120 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
120 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
121 $ mkcommit new_3_c
121 $ mkcommit new_3_c
122 created new head
122 created new head
123 $ hg debugobsolete -d '1338 0' `getid new_2_c` 1337133713371337133713371337133713371337
123 $ hg debugobsolete -d '1338 0' `getid new_2_c` 1337133713371337133713371337133713371337
124 obsoleted 1 changesets
124 obsoleted 1 changesets
125 $ hg debugobsolete -d '1339 0' 1337133713371337133713371337133713371337 `getid new_3_c`
125 $ hg debugobsolete -d '1339 0' 1337133713371337133713371337133713371337 `getid new_3_c`
126 $ hg debugobsolete
126 $ hg debugobsolete
127 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
127 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
128 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
128 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
129 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
129 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
130 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
130 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
131
131
132 Test the --index option of debugobsolete command
132 Test the --index option of debugobsolete command
133 $ hg debugobsolete --index
133 $ hg debugobsolete --index
134 0 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
134 0 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
135 1 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
135 1 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
136 2 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
136 2 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
137 3 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
137 3 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
138
138
139 Refuse pathological nullid successors
139 Refuse pathological nullid successors
140 $ hg debugobsolete -d '9001 0' 1337133713371337133713371337133713371337 0000000000000000000000000000000000000000
140 $ hg debugobsolete -d '9001 0' 1337133713371337133713371337133713371337 0000000000000000000000000000000000000000
141 transaction abort!
141 transaction abort!
142 rollback completed
142 rollback completed
143 abort: bad obsolescence marker detected: invalid successors nullid
143 abort: bad obsolescence marker detected: invalid successors nullid
144 [255]
144 [255]
145
145
146 Check that graphlog detect that a changeset is obsolete:
146 Check that graphlog detect that a changeset is obsolete:
147
147
148 $ hg log -G
148 $ hg log -G
149 @ 5:5601fb93a350 (draft) [tip ] add new_3_c
149 @ 5:5601fb93a350 (draft) [tip ] add new_3_c
150 |
150 |
151 o 1:7c3bad9141dc (draft) [ ] add b
151 o 1:7c3bad9141dc (draft) [ ] add b
152 |
152 |
153 o 0:1f0dee641bb7 (draft) [ ] add a
153 o 0:1f0dee641bb7 (draft) [ ] add a
154
154
155
155
156 check that heads does not report them
156 check that heads does not report them
157
157
158 $ hg heads
158 $ hg heads
159 5:5601fb93a350 (draft) [tip ] add new_3_c
159 5:5601fb93a350 (draft) [tip ] add new_3_c
160 $ hg heads --hidden
160 $ hg heads --hidden
161 5:5601fb93a350 (draft) [tip ] add new_3_c
161 5:5601fb93a350 (draft) [tip ] add new_3_c
162 4:ca819180edb9 (draft *obsolete*) [ ] add new_2_c
162 4:ca819180edb9 (draft *obsolete*) [ ] add new_2_c
163 3:cdbce2fbb163 (draft *obsolete*) [ ] add new_c
163 3:cdbce2fbb163 (draft *obsolete*) [ ] add new_c
164 2:245bde4270cd (draft *obsolete*) [ ] add original_c
164 2:245bde4270cd (draft *obsolete*) [ ] add original_c
165
165
166
166
167 check that summary does not report them
167 check that summary does not report them
168
168
169 $ hg init ../sink
169 $ hg init ../sink
170 $ echo '[paths]' >> .hg/hgrc
170 $ echo '[paths]' >> .hg/hgrc
171 $ echo 'default=../sink' >> .hg/hgrc
171 $ echo 'default=../sink' >> .hg/hgrc
172 $ hg summary --remote
172 $ hg summary --remote
173 parent: 5:5601fb93a350 tip
173 parent: 5:5601fb93a350 tip
174 add new_3_c
174 add new_3_c
175 branch: default
175 branch: default
176 commit: (clean)
176 commit: (clean)
177 update: (current)
177 update: (current)
178 phases: 3 draft
178 phases: 3 draft
179 remote: 3 outgoing
179 remote: 3 outgoing
180
180
181 $ hg summary --remote --hidden
181 $ hg summary --remote --hidden
182 parent: 5:5601fb93a350 tip
182 parent: 5:5601fb93a350 tip
183 add new_3_c
183 add new_3_c
184 branch: default
184 branch: default
185 commit: (clean)
185 commit: (clean)
186 update: 3 new changesets, 4 branch heads (merge)
186 update: 3 new changesets, 4 branch heads (merge)
187 phases: 6 draft
187 phases: 6 draft
188 remote: 3 outgoing
188 remote: 3 outgoing
189
189
190 check that various commands work well with filtering
190 check that various commands work well with filtering
191
191
192 $ hg tip
192 $ hg tip
193 5:5601fb93a350 (draft) [tip ] add new_3_c
193 5:5601fb93a350 (draft) [tip ] add new_3_c
194 $ hg log -r 6
194 $ hg log -r 6
195 abort: unknown revision '6'!
195 abort: unknown revision '6'!
196 [255]
196 [255]
197 $ hg log -r 4
197 $ hg log -r 4
198 abort: hidden revision '4'!
198 abort: hidden revision '4'!
199 (use --hidden to access hidden revisions)
199 (use --hidden to access hidden revisions)
200 [255]
200 [255]
201 $ hg debugrevspec 'rev(6)'
201 $ hg debugrevspec 'rev(6)'
202 $ hg debugrevspec 'rev(4)'
202 $ hg debugrevspec 'rev(4)'
203 $ hg debugrevspec 'null'
203 $ hg debugrevspec 'null'
204 -1
204 -1
205
205
206 Check that public changeset are not accounted as obsolete:
206 Check that public changeset are not accounted as obsolete:
207
207
208 $ hg --hidden phase --public 2
208 $ hg --hidden phase --public 2
209 $ hg log -G
209 $ hg log -G
210 @ 5:5601fb93a350 (draft phase-divergent) [tip ] add new_3_c
210 @ 5:5601fb93a350 (draft phase-divergent) [tip ] add new_3_c
211 |
211 |
212 | o 2:245bde4270cd (public) [ ] add original_c
212 | o 2:245bde4270cd (public) [ ] add original_c
213 |/
213 |/
214 o 1:7c3bad9141dc (public) [ ] add b
214 o 1:7c3bad9141dc (public) [ ] add b
215 |
215 |
216 o 0:1f0dee641bb7 (public) [ ] add a
216 o 0:1f0dee641bb7 (public) [ ] add a
217
217
218
218
219 And that bumped changeset are detected
219 And that bumped changeset are detected
220 --------------------------------------
220 --------------------------------------
221
221
222 If we didn't filtered obsolete changesets out, 3 and 4 would show up too. Also
222 If we didn't filtered obsolete changesets out, 3 and 4 would show up too. Also
223 note that the bumped changeset (5:5601fb93a350) is not a direct successor of
223 note that the bumped changeset (5:5601fb93a350) is not a direct successor of
224 the public changeset
224 the public changeset
225
225
226 $ hg log --hidden -r 'phasedivergent()'
226 $ hg log --hidden -r 'phasedivergent()'
227 5:5601fb93a350 (draft phase-divergent) [tip ] add new_3_c
227 5:5601fb93a350 (draft phase-divergent) [tip ] add new_3_c
228
228
229 And that we can't push bumped changeset
229 And that we can't push bumped changeset
230
230
231 $ hg push ../tmpa -r 0 --force #(make repo related)
231 $ hg push ../tmpa -r 0 --force #(make repo related)
232 pushing to ../tmpa
232 pushing to ../tmpa
233 searching for changes
233 searching for changes
234 warning: repository is unrelated
234 warning: repository is unrelated
235 adding changesets
235 adding changesets
236 adding manifests
236 adding manifests
237 adding file changes
237 adding file changes
238 added 1 changesets with 1 changes to 1 files (+1 heads)
238 added 1 changesets with 1 changes to 1 files (+1 heads)
239 $ hg push ../tmpa
239 $ hg push ../tmpa
240 pushing to ../tmpa
240 pushing to ../tmpa
241 searching for changes
241 searching for changes
242 abort: push includes phase-divergent changeset: 5601fb93a350!
242 abort: push includes phase-divergent changeset: 5601fb93a350!
243 [255]
243 [255]
244
244
245 Fixing "bumped" situation
245 Fixing "bumped" situation
246 We need to create a clone of 5 and add a special marker with a flag
246 We need to create a clone of 5 and add a special marker with a flag
247
247
248 $ hg summary
248 $ hg summary
249 parent: 5:5601fb93a350 tip (phase-divergent)
249 parent: 5:5601fb93a350 tip (phase-divergent)
250 add new_3_c
250 add new_3_c
251 branch: default
251 branch: default
252 commit: (clean)
252 commit: (clean)
253 update: 1 new changesets, 2 branch heads (merge)
253 update: 1 new changesets, 2 branch heads (merge)
254 phases: 1 draft
254 phases: 1 draft
255 phase-divergent: 1 changesets
255 phase-divergent: 1 changesets
256 $ hg up '5^'
256 $ hg up '5^'
257 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
257 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
258 $ hg revert -ar 5
258 $ hg revert -ar 5
259 adding new_3_c
259 adding new_3_c
260 $ hg ci -m 'add n3w_3_c'
260 $ hg ci -m 'add n3w_3_c'
261 created new head
261 created new head
262 $ hg debugobsolete -d '1338 0' --flags 1 `getid new_3_c` `getid n3w_3_c`
262 $ hg debugobsolete -d '1338 0' --flags 1 `getid new_3_c` `getid n3w_3_c`
263 obsoleted 1 changesets
263 obsoleted 1 changesets
264 $ hg log -r 'phasedivergent()'
264 $ hg log -r 'phasedivergent()'
265 $ hg log -G
265 $ hg log -G
266 @ 6:6f9641995072 (draft) [tip ] add n3w_3_c
266 @ 6:6f9641995072 (draft) [tip ] add n3w_3_c
267 |
267 |
268 | o 2:245bde4270cd (public) [ ] add original_c
268 | o 2:245bde4270cd (public) [ ] add original_c
269 |/
269 |/
270 o 1:7c3bad9141dc (public) [ ] add b
270 o 1:7c3bad9141dc (public) [ ] add b
271 |
271 |
272 o 0:1f0dee641bb7 (public) [ ] add a
272 o 0:1f0dee641bb7 (public) [ ] add a
273
273
274
274
275 Basic exclusive testing
275 Basic exclusive testing
276
276
277 $ hg log -G --hidden
277 $ hg log -G --hidden
278 @ 6:6f9641995072 (draft) [tip ] add n3w_3_c
278 @ 6:6f9641995072 (draft) [tip ] add n3w_3_c
279 |
279 |
280 | x 5:5601fb93a350 (draft *obsolete*) [ ] add new_3_c
280 | x 5:5601fb93a350 (draft *obsolete*) [ ] add new_3_c
281 |/
281 |/
282 | x 4:ca819180edb9 (draft *obsolete*) [ ] add new_2_c
282 | x 4:ca819180edb9 (draft *obsolete*) [ ] add new_2_c
283 |/
283 |/
284 | x 3:cdbce2fbb163 (draft *obsolete*) [ ] add new_c
284 | x 3:cdbce2fbb163 (draft *obsolete*) [ ] add new_c
285 |/
285 |/
286 | o 2:245bde4270cd (public) [ ] add original_c
286 | o 2:245bde4270cd (public) [ ] add original_c
287 |/
287 |/
288 o 1:7c3bad9141dc (public) [ ] add b
288 o 1:7c3bad9141dc (public) [ ] add b
289 |
289 |
290 o 0:1f0dee641bb7 (public) [ ] add a
290 o 0:1f0dee641bb7 (public) [ ] add a
291
291
292 $ hg debugobsolete --rev 6f9641995072
292 $ hg debugobsolete --rev 6f9641995072
293 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
293 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
294 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
294 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
295 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
295 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
296 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
296 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
297 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
297 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
298 $ hg debugobsolete --rev 6f9641995072 --exclusive
298 $ hg debugobsolete --rev 6f9641995072 --exclusive
299 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
299 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
300 $ hg debugobsolete --rev 5601fb93a350 --hidden
300 $ hg debugobsolete --rev 5601fb93a350 --hidden
301 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
301 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
302 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
302 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
303 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
303 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
304 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
304 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
305 $ hg debugobsolete --rev 5601fb93a350 --hidden --exclusive
305 $ hg debugobsolete --rev 5601fb93a350 --hidden --exclusive
306 $ hg debugobsolete --rev 5601fb93a350+6f9641995072 --hidden --exclusive
306 $ hg debugobsolete --rev 5601fb93a350+6f9641995072 --hidden --exclusive
307 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
307 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
308 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
308 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
309 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
309 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
310
310
311 $ cd ..
311 $ cd ..
312
312
313 Revision 0 is hidden
313 Revision 0 is hidden
314 --------------------
314 --------------------
315
315
316 $ hg init rev0hidden
316 $ hg init rev0hidden
317 $ cd rev0hidden
317 $ cd rev0hidden
318
318
319 $ mkcommit kill0
319 $ mkcommit kill0
320 $ hg up -q null
320 $ hg up -q null
321 $ hg debugobsolete `getid kill0`
321 $ hg debugobsolete `getid kill0`
322 obsoleted 1 changesets
322 obsoleted 1 changesets
323 $ mkcommit a
323 $ mkcommit a
324 $ mkcommit b
324 $ mkcommit b
325
325
326 Should pick the first visible revision as "repo" node
326 Should pick the first visible revision as "repo" node
327
327
328 $ hg archive ../archive-null
328 $ hg archive ../archive-null
329 $ cat ../archive-null/.hg_archival.txt
329 $ cat ../archive-null/.hg_archival.txt
330 repo: 1f0dee641bb7258c56bd60e93edfa2405381c41e
330 repo: 1f0dee641bb7258c56bd60e93edfa2405381c41e
331 node: 7c3bad9141dcb46ff89abf5f61856facd56e476c
331 node: 7c3bad9141dcb46ff89abf5f61856facd56e476c
332 branch: default
332 branch: default
333 latesttag: null
333 latesttag: null
334 latesttagdistance: 2
334 latesttagdistance: 2
335 changessincelatesttag: 2
335 changessincelatesttag: 2
336
336
337
337
338 $ cd ..
338 $ cd ..
339
339
340 Exchange Test
340 Exchange Test
341 ============================
341 ============================
342
342
343 Destination repo does not have any data
343 Destination repo does not have any data
344 ---------------------------------------
344 ---------------------------------------
345
345
346 Simple incoming test
346 Simple incoming test
347
347
348 $ hg init tmpc
348 $ hg init tmpc
349 $ cd tmpc
349 $ cd tmpc
350 $ hg incoming ../tmpb
350 $ hg incoming ../tmpb
351 comparing with ../tmpb
351 comparing with ../tmpb
352 0:1f0dee641bb7 (public) [ ] add a
352 0:1f0dee641bb7 (public) [ ] add a
353 1:7c3bad9141dc (public) [ ] add b
353 1:7c3bad9141dc (public) [ ] add b
354 2:245bde4270cd (public) [ ] add original_c
354 2:245bde4270cd (public) [ ] add original_c
355 6:6f9641995072 (draft) [tip ] add n3w_3_c
355 6:6f9641995072 (draft) [tip ] add n3w_3_c
356
356
357 Try to pull markers
357 Try to pull markers
358 (extinct changeset are excluded but marker are pushed)
358 (extinct changeset are excluded but marker are pushed)
359
359
360 $ hg pull ../tmpb
360 $ hg pull ../tmpb
361 pulling from ../tmpb
361 pulling from ../tmpb
362 requesting all changes
362 requesting all changes
363 adding changesets
363 adding changesets
364 adding manifests
364 adding manifests
365 adding file changes
365 adding file changes
366 added 4 changesets with 4 changes to 4 files (+1 heads)
366 added 4 changesets with 4 changes to 4 files (+1 heads)
367 5 new obsolescence markers
367 5 new obsolescence markers
368 (run 'hg heads' to see heads, 'hg merge' to merge)
368 (run 'hg heads' to see heads, 'hg merge' to merge)
369 $ hg debugobsolete
369 $ hg debugobsolete
370 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
370 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
371 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
371 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
372 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
372 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
373 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
373 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
374 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
374 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
375
375
376 Rollback//Transaction support
376 Rollback//Transaction support
377
377
378 $ hg debugobsolete -d '1340 0' aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb
378 $ hg debugobsolete -d '1340 0' aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb
379 $ hg debugobsolete
379 $ hg debugobsolete
380 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
380 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
381 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
381 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
382 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
382 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
383 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
383 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
384 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
384 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
385 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb 0 (Thu Jan 01 00:22:20 1970 +0000) {'user': 'test'}
385 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb 0 (Thu Jan 01 00:22:20 1970 +0000) {'user': 'test'}
386 $ hg rollback -n
386 $ hg rollback -n
387 repository tip rolled back to revision 3 (undo debugobsolete)
387 repository tip rolled back to revision 3 (undo debugobsolete)
388 $ hg rollback
388 $ hg rollback
389 repository tip rolled back to revision 3 (undo debugobsolete)
389 repository tip rolled back to revision 3 (undo debugobsolete)
390 $ hg debugobsolete
390 $ hg debugobsolete
391 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
391 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
392 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
392 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
393 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
393 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
394 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
394 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
395 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
395 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
396
396
397 $ cd ..
397 $ cd ..
398
398
399 Try to push markers
399 Try to push markers
400
400
401 $ hg init tmpd
401 $ hg init tmpd
402 $ hg -R tmpb push tmpd
402 $ hg -R tmpb push tmpd
403 pushing to tmpd
403 pushing to tmpd
404 searching for changes
404 searching for changes
405 adding changesets
405 adding changesets
406 adding manifests
406 adding manifests
407 adding file changes
407 adding file changes
408 added 4 changesets with 4 changes to 4 files (+1 heads)
408 added 4 changesets with 4 changes to 4 files (+1 heads)
409 5 new obsolescence markers
409 5 new obsolescence markers
410 $ hg -R tmpd debugobsolete | sort
410 $ hg -R tmpd debugobsolete | sort
411 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
411 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
412 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
412 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
413 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
413 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
414 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
414 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
415 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
415 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
416
416
417 Check obsolete keys are exchanged only if source has an obsolete store
417 Check obsolete keys are exchanged only if source has an obsolete store
418
418
419 $ hg init empty
419 $ hg init empty
420 $ hg --config extensions.debugkeys=debugkeys.py -R empty push tmpd
420 $ hg --config extensions.debugkeys=debugkeys.py -R empty push tmpd
421 pushing to tmpd
421 pushing to tmpd
422 listkeys phases
422 listkeys phases
423 listkeys bookmarks
423 listkeys bookmarks
424 no changes found
424 no changes found
425 listkeys phases
425 listkeys phases
426 [1]
426 [1]
427
427
428 clone support
428 clone support
429 (markers are copied and extinct changesets are included to allow hardlinks)
429 (markers are copied and extinct changesets are included to allow hardlinks)
430
430
431 $ hg clone tmpb clone-dest
431 $ hg clone tmpb clone-dest
432 updating to branch default
432 updating to branch default
433 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
433 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
434 $ hg -R clone-dest log -G --hidden
434 $ hg -R clone-dest log -G --hidden
435 @ 6:6f9641995072 (draft) [tip ] add n3w_3_c
435 @ 6:6f9641995072 (draft) [tip ] add n3w_3_c
436 |
436 |
437 | x 5:5601fb93a350 (draft *obsolete*) [ ] add new_3_c
437 | x 5:5601fb93a350 (draft *obsolete*) [ ] add new_3_c
438 |/
438 |/
439 | x 4:ca819180edb9 (draft *obsolete*) [ ] add new_2_c
439 | x 4:ca819180edb9 (draft *obsolete*) [ ] add new_2_c
440 |/
440 |/
441 | x 3:cdbce2fbb163 (draft *obsolete*) [ ] add new_c
441 | x 3:cdbce2fbb163 (draft *obsolete*) [ ] add new_c
442 |/
442 |/
443 | o 2:245bde4270cd (public) [ ] add original_c
443 | o 2:245bde4270cd (public) [ ] add original_c
444 |/
444 |/
445 o 1:7c3bad9141dc (public) [ ] add b
445 o 1:7c3bad9141dc (public) [ ] add b
446 |
446 |
447 o 0:1f0dee641bb7 (public) [ ] add a
447 o 0:1f0dee641bb7 (public) [ ] add a
448
448
449 $ hg -R clone-dest debugobsolete
449 $ hg -R clone-dest debugobsolete
450 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
450 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
451 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
451 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
452 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
452 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
453 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
453 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
454 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
454 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
455
455
456
456
457 Destination repo have existing data
457 Destination repo have existing data
458 ---------------------------------------
458 ---------------------------------------
459
459
460 On pull
460 On pull
461
461
462 $ hg init tmpe
462 $ hg init tmpe
463 $ cd tmpe
463 $ cd tmpe
464 $ hg debugobsolete -d '1339 0' 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00
464 $ hg debugobsolete -d '1339 0' 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00
465 $ hg pull ../tmpb
465 $ hg pull ../tmpb
466 pulling from ../tmpb
466 pulling from ../tmpb
467 requesting all changes
467 requesting all changes
468 adding changesets
468 adding changesets
469 adding manifests
469 adding manifests
470 adding file changes
470 adding file changes
471 added 4 changesets with 4 changes to 4 files (+1 heads)
471 added 4 changesets with 4 changes to 4 files (+1 heads)
472 5 new obsolescence markers
472 5 new obsolescence markers
473 (run 'hg heads' to see heads, 'hg merge' to merge)
473 (run 'hg heads' to see heads, 'hg merge' to merge)
474 $ hg debugobsolete
474 $ hg debugobsolete
475 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
475 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
476 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
476 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
477 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
477 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
478 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
478 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
479 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
479 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
480 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
480 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
481
481
482
482
483 On push
483 On push
484
484
485 $ hg push ../tmpc
485 $ hg push ../tmpc
486 pushing to ../tmpc
486 pushing to ../tmpc
487 searching for changes
487 searching for changes
488 no changes found
488 no changes found
489 1 new obsolescence markers
489 1 new obsolescence markers
490 [1]
490 [1]
491 $ hg -R ../tmpc debugobsolete
491 $ hg -R ../tmpc debugobsolete
492 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
492 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
493 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
493 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
494 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
494 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
495 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
495 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
496 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
496 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
497 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
497 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
498
498
499 detect outgoing obsolete and unstable
499 detect outgoing obsolete and unstable
500 ---------------------------------------
500 ---------------------------------------
501
501
502
502
503 $ hg log -G
503 $ hg log -G
504 o 3:6f9641995072 (draft) [tip ] add n3w_3_c
504 o 3:6f9641995072 (draft) [tip ] add n3w_3_c
505 |
505 |
506 | o 2:245bde4270cd (public) [ ] add original_c
506 | o 2:245bde4270cd (public) [ ] add original_c
507 |/
507 |/
508 o 1:7c3bad9141dc (public) [ ] add b
508 o 1:7c3bad9141dc (public) [ ] add b
509 |
509 |
510 o 0:1f0dee641bb7 (public) [ ] add a
510 o 0:1f0dee641bb7 (public) [ ] add a
511
511
512 $ hg up 'desc("n3w_3_c")'
512 $ hg up 'desc("n3w_3_c")'
513 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
513 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
514 $ mkcommit original_d
514 $ mkcommit original_d
515 $ mkcommit original_e
515 $ mkcommit original_e
516 $ hg debugobsolete --record-parents `getid original_d` -d '0 0'
516 $ hg debugobsolete --record-parents `getid original_d` -d '0 0'
517 obsoleted 1 changesets
517 obsoleted 1 changesets
518 $ hg debugobsolete | grep `getid original_d`
518 $ hg debugobsolete | grep `getid original_d`
519 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
519 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
520 $ hg log -r 'obsolete()'
520 $ hg log -r 'obsolete()'
521 4:94b33453f93b (draft *obsolete*) [ ] add original_d
521 4:94b33453f93b (draft *obsolete*) [ ] add original_d
522 $ hg summary
522 $ hg summary
523 parent: 5:cda648ca50f5 tip (orphan)
523 parent: 5:cda648ca50f5 tip (orphan)
524 add original_e
524 add original_e
525 branch: default
525 branch: default
526 commit: (clean)
526 commit: (clean)
527 update: 1 new changesets, 2 branch heads (merge)
527 update: 1 new changesets, 2 branch heads (merge)
528 phases: 3 draft
528 phases: 3 draft
529 orphan: 1 changesets
529 orphan: 1 changesets
530 $ hg log -G -r '::orphan()'
530 $ hg log -G -r '::orphan()'
531 @ 5:cda648ca50f5 (draft orphan) [tip ] add original_e
531 @ 5:cda648ca50f5 (draft orphan) [tip ] add original_e
532 |
532 |
533 x 4:94b33453f93b (draft *obsolete*) [ ] add original_d
533 x 4:94b33453f93b (draft *obsolete*) [ ] add original_d
534 |
534 |
535 o 3:6f9641995072 (draft) [ ] add n3w_3_c
535 o 3:6f9641995072 (draft) [ ] add n3w_3_c
536 |
536 |
537 o 1:7c3bad9141dc (public) [ ] add b
537 o 1:7c3bad9141dc (public) [ ] add b
538 |
538 |
539 o 0:1f0dee641bb7 (public) [ ] add a
539 o 0:1f0dee641bb7 (public) [ ] add a
540
540
541
541
542 refuse to push obsolete changeset
542 refuse to push obsolete changeset
543
543
544 $ hg push ../tmpc/ -r 'desc("original_d")'
544 $ hg push ../tmpc/ -r 'desc("original_d")'
545 pushing to ../tmpc/
545 pushing to ../tmpc/
546 searching for changes
546 searching for changes
547 abort: push includes obsolete changeset: 94b33453f93b!
547 abort: push includes obsolete changeset: 94b33453f93b!
548 [255]
548 [255]
549
549
550 refuse to push unstable changeset
550 refuse to push unstable changeset
551
551
552 $ hg push ../tmpc/
552 $ hg push ../tmpc/
553 pushing to ../tmpc/
553 pushing to ../tmpc/
554 searching for changes
554 searching for changes
555 abort: push includes orphan changeset: cda648ca50f5!
555 abort: push includes orphan changeset: cda648ca50f5!
556 [255]
556 [255]
557
557
558 Test that extinct changeset are properly detected
558 Test that extinct changeset are properly detected
559
559
560 $ hg log -r 'extinct()'
560 $ hg log -r 'extinct()'
561
561
562 Don't try to push extinct changeset
562 Don't try to push extinct changeset
563
563
564 $ hg init ../tmpf
564 $ hg init ../tmpf
565 $ hg out ../tmpf
565 $ hg out ../tmpf
566 comparing with ../tmpf
566 comparing with ../tmpf
567 searching for changes
567 searching for changes
568 0:1f0dee641bb7 (public) [ ] add a
568 0:1f0dee641bb7 (public) [ ] add a
569 1:7c3bad9141dc (public) [ ] add b
569 1:7c3bad9141dc (public) [ ] add b
570 2:245bde4270cd (public) [ ] add original_c
570 2:245bde4270cd (public) [ ] add original_c
571 3:6f9641995072 (draft) [ ] add n3w_3_c
571 3:6f9641995072 (draft) [ ] add n3w_3_c
572 4:94b33453f93b (draft *obsolete*) [ ] add original_d
572 4:94b33453f93b (draft *obsolete*) [ ] add original_d
573 5:cda648ca50f5 (draft orphan) [tip ] add original_e
573 5:cda648ca50f5 (draft orphan) [tip ] add original_e
574 $ hg push ../tmpf -f # -f because be push unstable too
574 $ hg push ../tmpf -f # -f because be push unstable too
575 pushing to ../tmpf
575 pushing to ../tmpf
576 searching for changes
576 searching for changes
577 adding changesets
577 adding changesets
578 adding manifests
578 adding manifests
579 adding file changes
579 adding file changes
580 added 6 changesets with 6 changes to 6 files (+1 heads)
580 added 6 changesets with 6 changes to 6 files (+1 heads)
581 7 new obsolescence markers
581 7 new obsolescence markers
582
582
583 no warning displayed
583 no warning displayed
584
584
585 $ hg push ../tmpf
585 $ hg push ../tmpf
586 pushing to ../tmpf
586 pushing to ../tmpf
587 searching for changes
587 searching for changes
588 no changes found
588 no changes found
589 [1]
589 [1]
590
590
591 Do not warn about new head when the new head is a successors of a remote one
591 Do not warn about new head when the new head is a successors of a remote one
592
592
593 $ hg log -G
593 $ hg log -G
594 @ 5:cda648ca50f5 (draft orphan) [tip ] add original_e
594 @ 5:cda648ca50f5 (draft orphan) [tip ] add original_e
595 |
595 |
596 x 4:94b33453f93b (draft *obsolete*) [ ] add original_d
596 x 4:94b33453f93b (draft *obsolete*) [ ] add original_d
597 |
597 |
598 o 3:6f9641995072 (draft) [ ] add n3w_3_c
598 o 3:6f9641995072 (draft) [ ] add n3w_3_c
599 |
599 |
600 | o 2:245bde4270cd (public) [ ] add original_c
600 | o 2:245bde4270cd (public) [ ] add original_c
601 |/
601 |/
602 o 1:7c3bad9141dc (public) [ ] add b
602 o 1:7c3bad9141dc (public) [ ] add b
603 |
603 |
604 o 0:1f0dee641bb7 (public) [ ] add a
604 o 0:1f0dee641bb7 (public) [ ] add a
605
605
606 $ hg up -q 'desc(n3w_3_c)'
606 $ hg up -q 'desc(n3w_3_c)'
607 $ mkcommit obsolete_e
607 $ mkcommit obsolete_e
608 created new head
608 created new head
609 $ hg debugobsolete `getid 'original_e'` `getid 'obsolete_e'` \
609 $ hg debugobsolete `getid 'original_e'` `getid 'obsolete_e'` \
610 > -u 'test <test@example.net>'
610 > -u 'test <test@example.net>'
611 obsoleted 1 changesets
611 obsoleted 1 changesets
612 $ hg outgoing ../tmpf # parasite hg outgoing testin
612 $ hg outgoing ../tmpf # parasite hg outgoing testin
613 comparing with ../tmpf
613 comparing with ../tmpf
614 searching for changes
614 searching for changes
615 6:3de5eca88c00 (draft) [tip ] add obsolete_e
615 6:3de5eca88c00 (draft) [tip ] add obsolete_e
616 $ hg push ../tmpf
616 $ hg push ../tmpf
617 pushing to ../tmpf
617 pushing to ../tmpf
618 searching for changes
618 searching for changes
619 adding changesets
619 adding changesets
620 adding manifests
620 adding manifests
621 adding file changes
621 adding file changes
622 added 1 changesets with 1 changes to 1 files (+1 heads)
622 added 1 changesets with 1 changes to 1 files (+1 heads)
623 1 new obsolescence markers
623 1 new obsolescence markers
624 obsoleted 1 changesets
624 obsoleted 1 changesets
625
625
626 test relevance computation
626 test relevance computation
627 ---------------------------------------
627 ---------------------------------------
628
628
629 Checking simple case of "marker relevance".
629 Checking simple case of "marker relevance".
630
630
631
631
632 Reminder of the repo situation
632 Reminder of the repo situation
633
633
634 $ hg log --hidden --graph
634 $ hg log --hidden --graph
635 @ 6:3de5eca88c00 (draft) [tip ] add obsolete_e
635 @ 6:3de5eca88c00 (draft) [tip ] add obsolete_e
636 |
636 |
637 | x 5:cda648ca50f5 (draft *obsolete*) [ ] add original_e
637 | x 5:cda648ca50f5 (draft *obsolete*) [ ] add original_e
638 | |
638 | |
639 | x 4:94b33453f93b (draft *obsolete*) [ ] add original_d
639 | x 4:94b33453f93b (draft *obsolete*) [ ] add original_d
640 |/
640 |/
641 o 3:6f9641995072 (draft) [ ] add n3w_3_c
641 o 3:6f9641995072 (draft) [ ] add n3w_3_c
642 |
642 |
643 | o 2:245bde4270cd (public) [ ] add original_c
643 | o 2:245bde4270cd (public) [ ] add original_c
644 |/
644 |/
645 o 1:7c3bad9141dc (public) [ ] add b
645 o 1:7c3bad9141dc (public) [ ] add b
646 |
646 |
647 o 0:1f0dee641bb7 (public) [ ] add a
647 o 0:1f0dee641bb7 (public) [ ] add a
648
648
649
649
650 List of all markers
650 List of all markers
651
651
652 $ hg debugobsolete
652 $ hg debugobsolete
653 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
653 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
654 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
654 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
655 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
655 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
656 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
656 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
657 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
657 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
658 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
658 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
659 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
659 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
660 cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test <test@example.net>'} (glob)
660 cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test <test@example.net>'} (glob)
661
661
662 List of changesets with no chain
662 List of changesets with no chain
663
663
664 $ hg debugobsolete --hidden --rev ::2
664 $ hg debugobsolete --hidden --rev ::2
665
665
666 List of changesets that are included on marker chain
666 List of changesets that are included on marker chain
667
667
668 $ hg debugobsolete --hidden --rev 6
668 $ hg debugobsolete --hidden --rev 6
669 cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test <test@example.net>'} (glob)
669 cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test <test@example.net>'} (glob)
670
670
671 List of changesets with a longer chain, (including a pruned children)
671 List of changesets with a longer chain, (including a pruned children)
672
672
673 $ hg debugobsolete --hidden --rev 3
673 $ hg debugobsolete --hidden --rev 3
674 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
674 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
675 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
675 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
676 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
676 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
677 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
677 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
678 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
678 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
679 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
679 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
680 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
680 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
681
681
682 List of both
682 List of both
683
683
684 $ hg debugobsolete --hidden --rev 3::6
684 $ hg debugobsolete --hidden --rev 3::6
685 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
685 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
686 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
686 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'}
687 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
687 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Thu Jan 01 00:00:01 1970 -0002) {'user': 'test'}
688 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
688 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
689 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
689 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
690 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
690 ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'}
691 cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test <test@example.net>'} (glob)
691 cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test <test@example.net>'} (glob)
692 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
692 cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'}
693
693
694 List of all markers in JSON
694 List of all markers in JSON
695
695
696 $ hg debugobsolete -Tjson
696 $ hg debugobsolete -Tjson
697 [
697 [
698 {
698 {
699 "date": [1339.0, 0],
699 "date": [1339.0, 0],
700 "flag": 0,
700 "flag": 0,
701 "metadata": {"user": "test"},
701 "metadata": {"user": "test"},
702 "precnode": "1339133913391339133913391339133913391339",
702 "precnode": "1339133913391339133913391339133913391339",
703 "succnodes": ["ca819180edb99ed25ceafb3e9584ac287e240b00"]
703 "succnodes": ["ca819180edb99ed25ceafb3e9584ac287e240b00"]
704 },
704 },
705 {
705 {
706 "date": [1339.0, 0],
706 "date": [1339.0, 0],
707 "flag": 0,
707 "flag": 0,
708 "metadata": {"user": "test"},
708 "metadata": {"user": "test"},
709 "precnode": "1337133713371337133713371337133713371337",
709 "precnode": "1337133713371337133713371337133713371337",
710 "succnodes": ["5601fb93a350734d935195fee37f4054c529ff39"]
710 "succnodes": ["5601fb93a350734d935195fee37f4054c529ff39"]
711 },
711 },
712 {
712 {
713 "date": [121.0, 120],
713 "date": [121.0, 120],
714 "flag": 12,
714 "flag": 12,
715 "metadata": {"user": "test"},
715 "metadata": {"user": "test"},
716 "precnode": "245bde4270cd1072a27757984f9cda8ba26f08ca",
716 "precnode": "245bde4270cd1072a27757984f9cda8ba26f08ca",
717 "succnodes": ["cdbce2fbb16313928851e97e0d85413f3f7eb77f"]
717 "succnodes": ["cdbce2fbb16313928851e97e0d85413f3f7eb77f"]
718 },
718 },
719 {
719 {
720 "date": [1338.0, 0],
720 "date": [1338.0, 0],
721 "flag": 1,
721 "flag": 1,
722 "metadata": {"user": "test"},
722 "metadata": {"user": "test"},
723 "precnode": "5601fb93a350734d935195fee37f4054c529ff39",
723 "precnode": "5601fb93a350734d935195fee37f4054c529ff39",
724 "succnodes": ["6f96419950729f3671185b847352890f074f7557"]
724 "succnodes": ["6f96419950729f3671185b847352890f074f7557"]
725 },
725 },
726 {
726 {
727 "date": [1338.0, 0],
727 "date": [1338.0, 0],
728 "flag": 0,
728 "flag": 0,
729 "metadata": {"user": "test"},
729 "metadata": {"user": "test"},
730 "precnode": "ca819180edb99ed25ceafb3e9584ac287e240b00",
730 "precnode": "ca819180edb99ed25ceafb3e9584ac287e240b00",
731 "succnodes": ["1337133713371337133713371337133713371337"]
731 "succnodes": ["1337133713371337133713371337133713371337"]
732 },
732 },
733 {
733 {
734 "date": [1337.0, 0],
734 "date": [1337.0, 0],
735 "flag": 0,
735 "flag": 0,
736 "metadata": {"user": "test"},
736 "metadata": {"user": "test"},
737 "precnode": "cdbce2fbb16313928851e97e0d85413f3f7eb77f",
737 "precnode": "cdbce2fbb16313928851e97e0d85413f3f7eb77f",
738 "succnodes": ["ca819180edb99ed25ceafb3e9584ac287e240b00"]
738 "succnodes": ["ca819180edb99ed25ceafb3e9584ac287e240b00"]
739 },
739 },
740 {
740 {
741 "date": [0.0, 0],
741 "date": [0.0, 0],
742 "flag": 0,
742 "flag": 0,
743 "metadata": {"user": "test"},
743 "metadata": {"user": "test"},
744 "parentnodes": ["6f96419950729f3671185b847352890f074f7557"],
744 "parentnodes": ["6f96419950729f3671185b847352890f074f7557"],
745 "precnode": "94b33453f93bdb8d457ef9b770851a618bf413e1",
745 "precnode": "94b33453f93bdb8d457ef9b770851a618bf413e1",
746 "succnodes": []
746 "succnodes": []
747 },
747 },
748 {
748 {
749 "date": *, (glob)
749 "date": *, (glob)
750 "flag": 0,
750 "flag": 0,
751 "metadata": {"user": "test <test@example.net>"},
751 "metadata": {"user": "test <test@example.net>"},
752 "precnode": "cda648ca50f50482b7055c0b0c4c117bba6733d9",
752 "precnode": "cda648ca50f50482b7055c0b0c4c117bba6733d9",
753 "succnodes": ["3de5eca88c00aa039da7399a220f4a5221faa585"]
753 "succnodes": ["3de5eca88c00aa039da7399a220f4a5221faa585"]
754 }
754 }
755 ]
755 ]
756
756
757 Template keywords
757 Template keywords
758
758
759 $ hg debugobsolete -r6 -T '{succnodes % "{node|short}"} {date|shortdate}\n'
759 $ hg debugobsolete -r6 -T '{succnodes % "{node|short}"} {date|shortdate}\n'
760 3de5eca88c00 ????-??-?? (glob)
760 3de5eca88c00 ????-??-?? (glob)
761 $ hg debugobsolete -r6 -T '{join(metadata % "{key}={value}", " ")}\n'
761 $ hg debugobsolete -r6 -T '{join(metadata % "{key}={value}", " ")}\n'
762 user=test <test@example.net>
762 user=test <test@example.net>
763 $ hg debugobsolete -r6 -T '{metadata}\n'
763 $ hg debugobsolete -r6 -T '{metadata}\n'
764 'user': 'test <test@example.net>'
764 'user': 'test <test@example.net>'
765 $ hg debugobsolete -r6 -T '{flag} {get(metadata, "user")}\n'
765 $ hg debugobsolete -r6 -T '{flag} {get(metadata, "user")}\n'
766 0 test <test@example.net>
766 0 test <test@example.net>
767
767
768 Test the debug output for exchange
768 Test the debug output for exchange
769 ----------------------------------
769 ----------------------------------
770
770
771 $ hg pull ../tmpb --config 'experimental.obsmarkers-exchange-debug=True' # bundle2
771 $ hg pull ../tmpb --config 'experimental.obsmarkers-exchange-debug=True' # bundle2
772 pulling from ../tmpb
772 pulling from ../tmpb
773 searching for changes
773 searching for changes
774 no changes found
774 no changes found
775 obsmarker-exchange: 346 bytes received
775 obsmarker-exchange: 346 bytes received
776
776
777 check hgweb does not explode
777 check hgweb does not explode
778 ====================================
778 ====================================
779
779
780 $ hg unbundle $TESTDIR/bundles/hgweb+obs.hg
780 $ hg unbundle $TESTDIR/bundles/hgweb+obs.hg
781 adding changesets
781 adding changesets
782 adding manifests
782 adding manifests
783 adding file changes
783 adding file changes
784 added 62 changesets with 63 changes to 9 files (+60 heads)
784 added 62 changesets with 63 changes to 9 files (+60 heads)
785 (run 'hg heads .' to see heads, 'hg merge' to merge)
785 (run 'hg heads .' to see heads, 'hg merge' to merge)
786 $ for node in `hg log -r 'desc(babar_)' --template '{node}\n'`;
786 $ for node in `hg log -r 'desc(babar_)' --template '{node}\n'`;
787 > do
787 > do
788 > hg debugobsolete $node
788 > hg debugobsolete $node
789 > done
789 > done
790 obsoleted 1 changesets
790 obsoleted 1 changesets
791 obsoleted 1 changesets
791 obsoleted 1 changesets
792 obsoleted 1 changesets
792 obsoleted 1 changesets
793 obsoleted 1 changesets
793 obsoleted 1 changesets
794 obsoleted 1 changesets
794 obsoleted 1 changesets
795 obsoleted 1 changesets
795 obsoleted 1 changesets
796 obsoleted 1 changesets
796 obsoleted 1 changesets
797 obsoleted 1 changesets
797 obsoleted 1 changesets
798 obsoleted 1 changesets
798 obsoleted 1 changesets
799 obsoleted 1 changesets
799 obsoleted 1 changesets
800 obsoleted 1 changesets
800 obsoleted 1 changesets
801 obsoleted 1 changesets
801 obsoleted 1 changesets
802 obsoleted 1 changesets
802 obsoleted 1 changesets
803 obsoleted 1 changesets
803 obsoleted 1 changesets
804 obsoleted 1 changesets
804 obsoleted 1 changesets
805 obsoleted 1 changesets
805 obsoleted 1 changesets
806 obsoleted 1 changesets
806 obsoleted 1 changesets
807 obsoleted 1 changesets
807 obsoleted 1 changesets
808 obsoleted 1 changesets
808 obsoleted 1 changesets
809 obsoleted 1 changesets
809 obsoleted 1 changesets
810 obsoleted 1 changesets
810 obsoleted 1 changesets
811 obsoleted 1 changesets
811 obsoleted 1 changesets
812 obsoleted 1 changesets
812 obsoleted 1 changesets
813 obsoleted 1 changesets
813 obsoleted 1 changesets
814 obsoleted 1 changesets
814 obsoleted 1 changesets
815 obsoleted 1 changesets
815 obsoleted 1 changesets
816 obsoleted 1 changesets
816 obsoleted 1 changesets
817 obsoleted 1 changesets
817 obsoleted 1 changesets
818 obsoleted 1 changesets
818 obsoleted 1 changesets
819 obsoleted 1 changesets
819 obsoleted 1 changesets
820 obsoleted 1 changesets
820 obsoleted 1 changesets
821 obsoleted 1 changesets
821 obsoleted 1 changesets
822 obsoleted 1 changesets
822 obsoleted 1 changesets
823 obsoleted 1 changesets
823 obsoleted 1 changesets
824 obsoleted 1 changesets
824 obsoleted 1 changesets
825 obsoleted 1 changesets
825 obsoleted 1 changesets
826 obsoleted 1 changesets
826 obsoleted 1 changesets
827 obsoleted 1 changesets
827 obsoleted 1 changesets
828 obsoleted 1 changesets
828 obsoleted 1 changesets
829 obsoleted 1 changesets
829 obsoleted 1 changesets
830 obsoleted 1 changesets
830 obsoleted 1 changesets
831 obsoleted 1 changesets
831 obsoleted 1 changesets
832 obsoleted 1 changesets
832 obsoleted 1 changesets
833 obsoleted 1 changesets
833 obsoleted 1 changesets
834 obsoleted 1 changesets
834 obsoleted 1 changesets
835 obsoleted 1 changesets
835 obsoleted 1 changesets
836 obsoleted 1 changesets
836 obsoleted 1 changesets
837 obsoleted 1 changesets
837 obsoleted 1 changesets
838 obsoleted 1 changesets
838 obsoleted 1 changesets
839 obsoleted 1 changesets
839 obsoleted 1 changesets
840 obsoleted 1 changesets
840 obsoleted 1 changesets
841 obsoleted 1 changesets
841 obsoleted 1 changesets
842 obsoleted 1 changesets
842 obsoleted 1 changesets
843 obsoleted 1 changesets
843 obsoleted 1 changesets
844 obsoleted 1 changesets
844 obsoleted 1 changesets
845 obsoleted 1 changesets
845 obsoleted 1 changesets
846 obsoleted 1 changesets
846 obsoleted 1 changesets
847 obsoleted 1 changesets
847 obsoleted 1 changesets
848 obsoleted 1 changesets
848 obsoleted 1 changesets
849 obsoleted 1 changesets
849 obsoleted 1 changesets
850 $ hg up tip
850 $ hg up tip
851 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
851 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
852
852
853 #if serve
853 #if serve
854
854
855 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
855 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
856 $ cat hg.pid >> $DAEMON_PIDS
856 $ cat hg.pid >> $DAEMON_PIDS
857
857
858 check changelog view
858 check changelog view
859
859
860 $ get-with-headers.py --headeronly localhost:$HGPORT 'shortlog/'
860 $ get-with-headers.py --headeronly localhost:$HGPORT 'shortlog/'
861 200 Script output follows
861 200 Script output follows
862
862
863 check graph view
863 check graph view
864
864
865 $ get-with-headers.py --headeronly localhost:$HGPORT 'graph'
865 $ get-with-headers.py --headeronly localhost:$HGPORT 'graph'
866 200 Script output follows
866 200 Script output follows
867
867
868 check filelog view
868 check filelog view
869
869
870 $ get-with-headers.py --headeronly localhost:$HGPORT 'log/'`hg log -r . -T "{node}"`/'babar'
870 $ get-with-headers.py --headeronly localhost:$HGPORT 'log/'`hg log -r . -T "{node}"`/'babar'
871 200 Script output follows
871 200 Script output follows
872
872
873 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/68'
873 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/68'
874 200 Script output follows
874 200 Script output follows
875 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/67'
875 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/67'
876 404 Not Found
876 404 Not Found
877 [1]
877 [1]
878
878
879 check that web.view config option:
879 check that web.view config option:
880
880
881 $ killdaemons.py hg.pid
881 $ killdaemons.py hg.pid
882 $ cat >> .hg/hgrc << EOF
882 $ cat >> .hg/hgrc << EOF
883 > [web]
883 > [web]
884 > view=all
884 > view=all
885 > EOF
885 > EOF
886 $ wait
886 $ wait
887 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
887 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
888 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/67'
888 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/67'
889 200 Script output follows
889 200 Script output follows
890 $ killdaemons.py hg.pid
890 $ killdaemons.py hg.pid
891
891
892 Checking _enable=False warning if obsolete marker exists
892 Checking _enable=False warning if obsolete marker exists
893
893
894 $ echo '[experimental]' >> $HGRCPATH
894 $ echo '[experimental]' >> $HGRCPATH
895 $ echo "stabilization=" >> $HGRCPATH
895 $ echo "stabilization=" >> $HGRCPATH
896 $ hg log -r tip
896 $ hg log -r tip
897 obsolete feature not enabled but 68 markers found!
897 obsolete feature not enabled but 68 markers found!
898 68:c15e9edfca13 (draft) [tip ] add celestine
898 68:c15e9edfca13 (draft) [tip ] add celestine
899
899
900 reenable for later test
900 reenable for later test
901
901
902 $ echo '[experimental]' >> $HGRCPATH
902 $ echo '[experimental]' >> $HGRCPATH
903 $ echo "stabilization=createmarkers,exchange" >> $HGRCPATH
903 $ echo "stabilization=createmarkers,exchange" >> $HGRCPATH
904
904
905 $ rm hg.pid access.log errors.log
905 $ rm hg.pid access.log errors.log
906 #endif
906 #endif
907
907
908 Several troubles on the same changeset (create an unstable and bumped changeset)
908 Several troubles on the same changeset (create an unstable and bumped changeset)
909
909
910 $ hg debugobsolete `getid obsolete_e`
910 $ hg debugobsolete `getid obsolete_e`
911 obsoleted 1 changesets
911 obsoleted 1 changesets
912 $ hg debugobsolete `getid original_c` `getid babar`
912 $ hg debugobsolete `getid original_c` `getid babar`
913 $ hg log --config ui.logtemplate= -r 'phasedivergent() and orphan()'
913 $ hg log --config ui.logtemplate= -r 'phasedivergent() and orphan()'
914 changeset: 7:50c51b361e60
914 changeset: 7:50c51b361e60
915 user: test
915 user: test
916 date: Thu Jan 01 00:00:00 1970 +0000
916 date: Thu Jan 01 00:00:00 1970 +0000
917 instability: orphan, phase-divergent
917 instability: orphan, phase-divergent
918 summary: add babar
918 summary: add babar
919
919
920
920
921 test the "obsolete" templatekw
921 test the "obsolete" templatekw
922
922
923 $ hg log -r 'obsolete()'
923 $ hg log -r 'obsolete()'
924 6:3de5eca88c00 (draft *obsolete*) [ ] add obsolete_e
924 6:3de5eca88c00 (draft *obsolete*) [ ] add obsolete_e
925
925
926 test the "troubles" templatekw
926 test the "troubles" templatekw
927
927
928 $ hg log -r 'phasedivergent() and orphan()'
928 $ hg log -r 'phasedivergent() and orphan()'
929 7:50c51b361e60 (draft orphan phase-divergent) [ ] add babar
929 7:50c51b361e60 (draft orphan phase-divergent) [ ] add babar
930
930
931 test the default cmdline template
931 test the default cmdline template
932
932
933 $ hg log -T default -r 'phasedivergent()'
933 $ hg log -T default -r 'phasedivergent()'
934 changeset: 7:50c51b361e60
934 changeset: 7:50c51b361e60
935 user: test
935 user: test
936 date: Thu Jan 01 00:00:00 1970 +0000
936 date: Thu Jan 01 00:00:00 1970 +0000
937 instability: orphan, phase-divergent
937 instability: orphan, phase-divergent
938 summary: add babar
938 summary: add babar
939
939
940 $ hg log -T default -r 'obsolete()'
940 $ hg log -T default -r 'obsolete()'
941 changeset: 6:3de5eca88c00
941 changeset: 6:3de5eca88c00
942 parent: 3:6f9641995072
942 parent: 3:6f9641995072
943 user: test
943 user: test
944 date: Thu Jan 01 00:00:00 1970 +0000
944 date: Thu Jan 01 00:00:00 1970 +0000
945 summary: add obsolete_e
945 summary: add obsolete_e
946
946
947
947
948 test the obsolete labels
949
950 $ hg log --config ui.logtemplate= --color=debug -r 'phasedivergent()'
951 [log.changeset changeset.draft changeset.troubled trouble.orphan trouble.phase-divergent|changeset: 7:50c51b361e60]
952 [log.user|user: test]
953 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
954 [log.trouble|instability: orphan, phase-divergent]
955 [log.summary|summary: add babar]
956
957
958 $ hg log -T default -r 'phasedivergent()' --color=debug
959 [log.changeset changeset.draft changeset.troubled trouble.orphantrouble.phase-divergent|changeset: 7:50c51b361e60]
960 [log.user|user: test]
961 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
962 [log.trouble|instability: orphan, phase-divergent]
963 [log.summary|summary: add babar]
964
965
966 $ hg log --config ui.logtemplate= --color=debug -r "obsolete()"
967 [log.changeset changeset.draft changeset.obsolete|changeset: 6:3de5eca88c00]
968 [log.parent changeset.draft|parent: 3:6f9641995072]
969 [log.user|user: test]
970 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
971 [log.summary|summary: add obsolete_e]
972
973
974 $ hg log -T default -r 'obsolete()' --color=debug
975 [log.changeset changeset.draft changeset.obsolete|changeset: 6:3de5eca88c00]
976 [log.parent changeset.draft|parent: 3:6f9641995072]
977 [log.user|user: test]
978 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
979 [log.summary|summary: add obsolete_e]
980
981
948 test summary output
982 test summary output
949
983
950 $ hg up -r 'phasedivergent() and orphan()'
984 $ hg up -r 'phasedivergent() and orphan()'
951 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
985 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
952 $ hg summary
986 $ hg summary
953 parent: 7:50c51b361e60 (orphan, phase-divergent)
987 parent: 7:50c51b361e60 (orphan, phase-divergent)
954 add babar
988 add babar
955 branch: default
989 branch: default
956 commit: (clean)
990 commit: (clean)
957 update: 2 new changesets (update)
991 update: 2 new changesets (update)
958 phases: 4 draft
992 phases: 4 draft
959 orphan: 2 changesets
993 orphan: 2 changesets
960 phase-divergent: 1 changesets
994 phase-divergent: 1 changesets
961 $ hg up -r 'obsolete()'
995 $ hg up -r 'obsolete()'
962 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
996 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
963 $ hg summary
997 $ hg summary
964 parent: 6:3de5eca88c00 (obsolete)
998 parent: 6:3de5eca88c00 (obsolete)
965 add obsolete_e
999 add obsolete_e
966 branch: default
1000 branch: default
967 commit: (clean)
1001 commit: (clean)
968 update: 3 new changesets (update)
1002 update: 3 new changesets (update)
969 phases: 4 draft
1003 phases: 4 draft
970 orphan: 2 changesets
1004 orphan: 2 changesets
971 phase-divergent: 1 changesets
1005 phase-divergent: 1 changesets
972
1006
973 Test incoming/outcoming with changesets obsoleted remotely, known locally
1007 Test incoming/outcoming with changesets obsoleted remotely, known locally
974 ===============================================================================
1008 ===============================================================================
975
1009
976 This test issue 3805
1010 This test issue 3805
977
1011
978 $ hg init repo-issue3805
1012 $ hg init repo-issue3805
979 $ cd repo-issue3805
1013 $ cd repo-issue3805
980 $ echo "base" > base
1014 $ echo "base" > base
981 $ hg ci -Am "base"
1015 $ hg ci -Am "base"
982 adding base
1016 adding base
983 $ echo "foo" > foo
1017 $ echo "foo" > foo
984 $ hg ci -Am "A"
1018 $ hg ci -Am "A"
985 adding foo
1019 adding foo
986 $ hg clone . ../other-issue3805
1020 $ hg clone . ../other-issue3805
987 updating to branch default
1021 updating to branch default
988 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
1022 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
989 $ echo "bar" >> foo
1023 $ echo "bar" >> foo
990 $ hg ci --amend
1024 $ hg ci --amend
991 $ cd ../other-issue3805
1025 $ cd ../other-issue3805
992 $ hg log -G
1026 $ hg log -G
993 @ 1:29f0c6921ddd (draft) [tip ] A
1027 @ 1:29f0c6921ddd (draft) [tip ] A
994 |
1028 |
995 o 0:d20a80d4def3 (draft) [ ] base
1029 o 0:d20a80d4def3 (draft) [ ] base
996
1030
997 $ hg log -G -R ../repo-issue3805
1031 $ hg log -G -R ../repo-issue3805
998 @ 3:323a9c3ddd91 (draft) [tip ] A
1032 @ 3:323a9c3ddd91 (draft) [tip ] A
999 |
1033 |
1000 o 0:d20a80d4def3 (draft) [ ] base
1034 o 0:d20a80d4def3 (draft) [ ] base
1001
1035
1002 $ hg incoming
1036 $ hg incoming
1003 comparing with $TESTTMP/tmpe/repo-issue3805 (glob)
1037 comparing with $TESTTMP/tmpe/repo-issue3805 (glob)
1004 searching for changes
1038 searching for changes
1005 3:323a9c3ddd91 (draft) [tip ] A
1039 3:323a9c3ddd91 (draft) [tip ] A
1006 $ hg incoming --bundle ../issue3805.hg
1040 $ hg incoming --bundle ../issue3805.hg
1007 comparing with $TESTTMP/tmpe/repo-issue3805 (glob)
1041 comparing with $TESTTMP/tmpe/repo-issue3805 (glob)
1008 searching for changes
1042 searching for changes
1009 3:323a9c3ddd91 (draft) [tip ] A
1043 3:323a9c3ddd91 (draft) [tip ] A
1010 $ hg outgoing
1044 $ hg outgoing
1011 comparing with $TESTTMP/tmpe/repo-issue3805 (glob)
1045 comparing with $TESTTMP/tmpe/repo-issue3805 (glob)
1012 searching for changes
1046 searching for changes
1013 1:29f0c6921ddd (draft) [tip ] A
1047 1:29f0c6921ddd (draft) [tip ] A
1014
1048
1015 #if serve
1049 #if serve
1016
1050
1017 $ hg serve -R ../repo-issue3805 -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
1051 $ hg serve -R ../repo-issue3805 -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
1018 $ cat hg.pid >> $DAEMON_PIDS
1052 $ cat hg.pid >> $DAEMON_PIDS
1019
1053
1020 $ hg incoming http://localhost:$HGPORT
1054 $ hg incoming http://localhost:$HGPORT
1021 comparing with http://localhost:$HGPORT/
1055 comparing with http://localhost:$HGPORT/
1022 searching for changes
1056 searching for changes
1023 2:323a9c3ddd91 (draft) [tip ] A
1057 2:323a9c3ddd91 (draft) [tip ] A
1024 $ hg outgoing http://localhost:$HGPORT
1058 $ hg outgoing http://localhost:$HGPORT
1025 comparing with http://localhost:$HGPORT/
1059 comparing with http://localhost:$HGPORT/
1026 searching for changes
1060 searching for changes
1027 1:29f0c6921ddd (draft) [tip ] A
1061 1:29f0c6921ddd (draft) [tip ] A
1028
1062
1029 $ killdaemons.py
1063 $ killdaemons.py
1030
1064
1031 #endif
1065 #endif
1032
1066
1033 This test issue 3814
1067 This test issue 3814
1034
1068
1035 (nothing to push but locally hidden changeset)
1069 (nothing to push but locally hidden changeset)
1036
1070
1037 $ cd ..
1071 $ cd ..
1038 $ hg init repo-issue3814
1072 $ hg init repo-issue3814
1039 $ cd repo-issue3805
1073 $ cd repo-issue3805
1040 $ hg push -r 323a9c3ddd91 ../repo-issue3814
1074 $ hg push -r 323a9c3ddd91 ../repo-issue3814
1041 pushing to ../repo-issue3814
1075 pushing to ../repo-issue3814
1042 searching for changes
1076 searching for changes
1043 adding changesets
1077 adding changesets
1044 adding manifests
1078 adding manifests
1045 adding file changes
1079 adding file changes
1046 added 2 changesets with 2 changes to 2 files
1080 added 2 changesets with 2 changes to 2 files
1047 2 new obsolescence markers
1081 2 new obsolescence markers
1048 $ hg out ../repo-issue3814
1082 $ hg out ../repo-issue3814
1049 comparing with ../repo-issue3814
1083 comparing with ../repo-issue3814
1050 searching for changes
1084 searching for changes
1051 no changes found
1085 no changes found
1052 [1]
1086 [1]
1053
1087
1054 Test that a local tag blocks a changeset from being hidden
1088 Test that a local tag blocks a changeset from being hidden
1055
1089
1056 $ hg tag -l visible -r 1 --hidden
1090 $ hg tag -l visible -r 1 --hidden
1057 $ hg log -G
1091 $ hg log -G
1058 @ 3:323a9c3ddd91 (draft) [tip ] A
1092 @ 3:323a9c3ddd91 (draft) [tip ] A
1059 |
1093 |
1060 | x 1:29f0c6921ddd (draft *obsolete*) [visible ] A
1094 | x 1:29f0c6921ddd (draft *obsolete*) [visible ] A
1061 |/
1095 |/
1062 o 0:d20a80d4def3 (draft) [ ] base
1096 o 0:d20a80d4def3 (draft) [ ] base
1063
1097
1064 Test that removing a local tag does not cause some commands to fail
1098 Test that removing a local tag does not cause some commands to fail
1065
1099
1066 $ hg tag -l -r tip tiptag
1100 $ hg tag -l -r tip tiptag
1067 $ hg tags
1101 $ hg tags
1068 tiptag 3:323a9c3ddd91
1102 tiptag 3:323a9c3ddd91
1069 tip 3:323a9c3ddd91
1103 tip 3:323a9c3ddd91
1070 visible 1:29f0c6921ddd
1104 visible 1:29f0c6921ddd
1071 $ hg --config extensions.strip= strip -r tip --no-backup
1105 $ hg --config extensions.strip= strip -r tip --no-backup
1072 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1106 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1073 $ hg tags
1107 $ hg tags
1074 visible 1:29f0c6921ddd
1108 visible 1:29f0c6921ddd
1075 tip 1:29f0c6921ddd
1109 tip 1:29f0c6921ddd
1076
1110
1077 Test bundle overlay onto hidden revision
1111 Test bundle overlay onto hidden revision
1078
1112
1079 $ cd ..
1113 $ cd ..
1080 $ hg init repo-bundleoverlay
1114 $ hg init repo-bundleoverlay
1081 $ cd repo-bundleoverlay
1115 $ cd repo-bundleoverlay
1082 $ echo "A" > foo
1116 $ echo "A" > foo
1083 $ hg ci -Am "A"
1117 $ hg ci -Am "A"
1084 adding foo
1118 adding foo
1085 $ echo "B" >> foo
1119 $ echo "B" >> foo
1086 $ hg ci -m "B"
1120 $ hg ci -m "B"
1087 $ hg up 0
1121 $ hg up 0
1088 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1122 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1089 $ echo "C" >> foo
1123 $ echo "C" >> foo
1090 $ hg ci -m "C"
1124 $ hg ci -m "C"
1091 created new head
1125 created new head
1092 $ hg log -G
1126 $ hg log -G
1093 @ 2:c186d7714947 (draft) [tip ] C
1127 @ 2:c186d7714947 (draft) [tip ] C
1094 |
1128 |
1095 | o 1:44526ebb0f98 (draft) [ ] B
1129 | o 1:44526ebb0f98 (draft) [ ] B
1096 |/
1130 |/
1097 o 0:4b34ecfb0d56 (draft) [ ] A
1131 o 0:4b34ecfb0d56 (draft) [ ] A
1098
1132
1099
1133
1100 $ hg clone -r1 . ../other-bundleoverlay
1134 $ hg clone -r1 . ../other-bundleoverlay
1101 adding changesets
1135 adding changesets
1102 adding manifests
1136 adding manifests
1103 adding file changes
1137 adding file changes
1104 added 2 changesets with 2 changes to 1 files
1138 added 2 changesets with 2 changes to 1 files
1105 updating to branch default
1139 updating to branch default
1106 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1140 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1107 $ cd ../other-bundleoverlay
1141 $ cd ../other-bundleoverlay
1108 $ echo "B+" >> foo
1142 $ echo "B+" >> foo
1109 $ hg ci --amend -m "B+"
1143 $ hg ci --amend -m "B+"
1110 $ hg log -G --hidden
1144 $ hg log -G --hidden
1111 @ 3:b7d587542d40 (draft) [tip ] B+
1145 @ 3:b7d587542d40 (draft) [tip ] B+
1112 |
1146 |
1113 | x 2:eb95e9297e18 (draft *obsolete*) [ ] temporary amend commit for 44526ebb0f98
1147 | x 2:eb95e9297e18 (draft *obsolete*) [ ] temporary amend commit for 44526ebb0f98
1114 | |
1148 | |
1115 | x 1:44526ebb0f98 (draft *obsolete*) [ ] B
1149 | x 1:44526ebb0f98 (draft *obsolete*) [ ] B
1116 |/
1150 |/
1117 o 0:4b34ecfb0d56 (draft) [ ] A
1151 o 0:4b34ecfb0d56 (draft) [ ] A
1118
1152
1119
1153
1120 $ hg incoming ../repo-bundleoverlay --bundle ../bundleoverlay.hg
1154 $ hg incoming ../repo-bundleoverlay --bundle ../bundleoverlay.hg
1121 comparing with ../repo-bundleoverlay
1155 comparing with ../repo-bundleoverlay
1122 searching for changes
1156 searching for changes
1123 1:44526ebb0f98 (draft) [ ] B
1157 1:44526ebb0f98 (draft) [ ] B
1124 2:c186d7714947 (draft) [tip ] C
1158 2:c186d7714947 (draft) [tip ] C
1125 $ hg log -G -R ../bundleoverlay.hg
1159 $ hg log -G -R ../bundleoverlay.hg
1126 o 4:c186d7714947 (draft) [tip ] C
1160 o 4:c186d7714947 (draft) [tip ] C
1127 |
1161 |
1128 | @ 3:b7d587542d40 (draft) [ ] B+
1162 | @ 3:b7d587542d40 (draft) [ ] B+
1129 |/
1163 |/
1130 o 0:4b34ecfb0d56 (draft) [ ] A
1164 o 0:4b34ecfb0d56 (draft) [ ] A
1131
1165
1132
1166
1133 #if serve
1167 #if serve
1134
1168
1135 Test issue 4506
1169 Test issue 4506
1136
1170
1137 $ cd ..
1171 $ cd ..
1138 $ hg init repo-issue4506
1172 $ hg init repo-issue4506
1139 $ cd repo-issue4506
1173 $ cd repo-issue4506
1140 $ echo "0" > foo
1174 $ echo "0" > foo
1141 $ hg add foo
1175 $ hg add foo
1142 $ hg ci -m "content-0"
1176 $ hg ci -m "content-0"
1143
1177
1144 $ hg up null
1178 $ hg up null
1145 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1179 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1146 $ echo "1" > bar
1180 $ echo "1" > bar
1147 $ hg add bar
1181 $ hg add bar
1148 $ hg ci -m "content-1"
1182 $ hg ci -m "content-1"
1149 created new head
1183 created new head
1150 $ hg up 0
1184 $ hg up 0
1151 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
1185 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
1152 $ hg graft 1
1186 $ hg graft 1
1153 grafting 1:1c9eddb02162 "content-1" (tip)
1187 grafting 1:1c9eddb02162 "content-1" (tip)
1154
1188
1155 $ hg debugobsolete `hg log -r1 -T'{node}'` `hg log -r2 -T'{node}'`
1189 $ hg debugobsolete `hg log -r1 -T'{node}'` `hg log -r2 -T'{node}'`
1156 obsoleted 1 changesets
1190 obsoleted 1 changesets
1157
1191
1158 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
1192 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log
1159 $ cat hg.pid >> $DAEMON_PIDS
1193 $ cat hg.pid >> $DAEMON_PIDS
1160
1194
1161 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/1'
1195 $ get-with-headers.py --headeronly localhost:$HGPORT 'rev/1'
1162 404 Not Found
1196 404 Not Found
1163 [1]
1197 [1]
1164 $ get-with-headers.py --headeronly localhost:$HGPORT 'file/tip/bar'
1198 $ get-with-headers.py --headeronly localhost:$HGPORT 'file/tip/bar'
1165 200 Script output follows
1199 200 Script output follows
1166 $ get-with-headers.py --headeronly localhost:$HGPORT 'annotate/tip/bar'
1200 $ get-with-headers.py --headeronly localhost:$HGPORT 'annotate/tip/bar'
1167 200 Script output follows
1201 200 Script output follows
1168
1202
1169 $ killdaemons.py
1203 $ killdaemons.py
1170
1204
1171 #endif
1205 #endif
1172
1206
1173 Test heads computation on pending index changes with obsolescence markers
1207 Test heads computation on pending index changes with obsolescence markers
1174 $ cd ..
1208 $ cd ..
1175 $ cat >$TESTTMP/test_extension.py << EOF
1209 $ cat >$TESTTMP/test_extension.py << EOF
1176 > from mercurial import cmdutil, registrar
1210 > from mercurial import cmdutil, registrar
1177 > from mercurial.i18n import _
1211 > from mercurial.i18n import _
1178 >
1212 >
1179 > cmdtable = {}
1213 > cmdtable = {}
1180 > command = registrar.command(cmdtable)
1214 > command = registrar.command(cmdtable)
1181 > @command(b"amendtransient",[], _('hg amendtransient [rev]'))
1215 > @command(b"amendtransient",[], _('hg amendtransient [rev]'))
1182 > def amend(ui, repo, *pats, **opts):
1216 > def amend(ui, repo, *pats, **opts):
1183 > def commitfunc(ui, repo, message, match, opts):
1217 > def commitfunc(ui, repo, message, match, opts):
1184 > return repo.commit(message, repo['.'].user(), repo['.'].date(), match)
1218 > return repo.commit(message, repo['.'].user(), repo['.'].date(), match)
1185 > opts['message'] = 'Test'
1219 > opts['message'] = 'Test'
1186 > opts['logfile'] = None
1220 > opts['logfile'] = None
1187 > cmdutil.amend(ui, repo, commitfunc, repo['.'], {}, pats, opts)
1221 > cmdutil.amend(ui, repo, commitfunc, repo['.'], {}, pats, opts)
1188 > ui.write('%s\n' % repo.changelog.headrevs())
1222 > ui.write('%s\n' % repo.changelog.headrevs())
1189 > EOF
1223 > EOF
1190 $ cat >> $HGRCPATH << EOF
1224 $ cat >> $HGRCPATH << EOF
1191 > [extensions]
1225 > [extensions]
1192 > testextension=$TESTTMP/test_extension.py
1226 > testextension=$TESTTMP/test_extension.py
1193 > EOF
1227 > EOF
1194 $ hg init repo-issue-nativerevs-pending-changes
1228 $ hg init repo-issue-nativerevs-pending-changes
1195 $ cd repo-issue-nativerevs-pending-changes
1229 $ cd repo-issue-nativerevs-pending-changes
1196 $ mkcommit a
1230 $ mkcommit a
1197 $ mkcommit b
1231 $ mkcommit b
1198 $ hg up ".^"
1232 $ hg up ".^"
1199 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1233 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1200 $ echo aa > a
1234 $ echo aa > a
1201 $ hg amendtransient
1235 $ hg amendtransient
1202 [1, 3]
1236 [1, 3]
1203
1237
1204 Test cache consistency for the visible filter
1238 Test cache consistency for the visible filter
1205 1) We want to make sure that the cached filtered revs are invalidated when
1239 1) We want to make sure that the cached filtered revs are invalidated when
1206 bookmarks change
1240 bookmarks change
1207 $ cd ..
1241 $ cd ..
1208 $ cat >$TESTTMP/test_extension.py << EOF
1242 $ cat >$TESTTMP/test_extension.py << EOF
1209 > import weakref
1243 > import weakref
1210 > from mercurial import cmdutil, extensions, bookmarks, repoview
1244 > from mercurial import cmdutil, extensions, bookmarks, repoview
1211 > def _bookmarkchanged(orig, bkmstoreinst, *args, **kwargs):
1245 > def _bookmarkchanged(orig, bkmstoreinst, *args, **kwargs):
1212 > reporef = weakref.ref(bkmstoreinst._repo)
1246 > reporef = weakref.ref(bkmstoreinst._repo)
1213 > def trhook(tr):
1247 > def trhook(tr):
1214 > repo = reporef()
1248 > repo = reporef()
1215 > hidden1 = repoview.computehidden(repo)
1249 > hidden1 = repoview.computehidden(repo)
1216 > hidden = repoview.filterrevs(repo, 'visible')
1250 > hidden = repoview.filterrevs(repo, 'visible')
1217 > if sorted(hidden1) != sorted(hidden):
1251 > if sorted(hidden1) != sorted(hidden):
1218 > print "cache inconsistency"
1252 > print "cache inconsistency"
1219 > bkmstoreinst._repo.currenttransaction().addpostclose('test_extension', trhook)
1253 > bkmstoreinst._repo.currenttransaction().addpostclose('test_extension', trhook)
1220 > orig(bkmstoreinst, *args, **kwargs)
1254 > orig(bkmstoreinst, *args, **kwargs)
1221 > def extsetup(ui):
1255 > def extsetup(ui):
1222 > extensions.wrapfunction(bookmarks.bmstore, '_recordchange',
1256 > extensions.wrapfunction(bookmarks.bmstore, '_recordchange',
1223 > _bookmarkchanged)
1257 > _bookmarkchanged)
1224 > EOF
1258 > EOF
1225
1259
1226 $ hg init repo-cache-inconsistency
1260 $ hg init repo-cache-inconsistency
1227 $ cd repo-issue-nativerevs-pending-changes
1261 $ cd repo-issue-nativerevs-pending-changes
1228 $ mkcommit a
1262 $ mkcommit a
1229 a already tracked!
1263 a already tracked!
1230 $ mkcommit b
1264 $ mkcommit b
1231 $ hg id
1265 $ hg id
1232 13bedc178fce tip
1266 13bedc178fce tip
1233 $ echo "hello" > b
1267 $ echo "hello" > b
1234 $ hg commit --amend -m "message"
1268 $ hg commit --amend -m "message"
1235 $ hg book bookb -r 13bedc178fce --hidden
1269 $ hg book bookb -r 13bedc178fce --hidden
1236 $ hg log -r 13bedc178fce
1270 $ hg log -r 13bedc178fce
1237 5:13bedc178fce (draft *obsolete*) [ bookb] add b
1271 5:13bedc178fce (draft *obsolete*) [ bookb] add b
1238 $ hg book -d bookb
1272 $ hg book -d bookb
1239 $ hg log -r 13bedc178fce
1273 $ hg log -r 13bedc178fce
1240 abort: hidden revision '13bedc178fce'!
1274 abort: hidden revision '13bedc178fce'!
1241 (use --hidden to access hidden revisions)
1275 (use --hidden to access hidden revisions)
1242 [255]
1276 [255]
1243
1277
1244 Empty out the test extension, as it isn't compatible with later parts
1278 Empty out the test extension, as it isn't compatible with later parts
1245 of the test.
1279 of the test.
1246 $ echo > $TESTTMP/test_extension.py
1280 $ echo > $TESTTMP/test_extension.py
1247
1281
1248 Test ability to pull changeset with locally applying obsolescence markers
1282 Test ability to pull changeset with locally applying obsolescence markers
1249 (issue4945)
1283 (issue4945)
1250
1284
1251 $ cd ..
1285 $ cd ..
1252 $ hg init issue4845
1286 $ hg init issue4845
1253 $ cd issue4845
1287 $ cd issue4845
1254
1288
1255 $ echo foo > f0
1289 $ echo foo > f0
1256 $ hg add f0
1290 $ hg add f0
1257 $ hg ci -m '0'
1291 $ hg ci -m '0'
1258 $ echo foo > f1
1292 $ echo foo > f1
1259 $ hg add f1
1293 $ hg add f1
1260 $ hg ci -m '1'
1294 $ hg ci -m '1'
1261 $ echo foo > f2
1295 $ echo foo > f2
1262 $ hg add f2
1296 $ hg add f2
1263 $ hg ci -m '2'
1297 $ hg ci -m '2'
1264
1298
1265 $ echo bar > f2
1299 $ echo bar > f2
1266 $ hg commit --amend --config experimetnal.stabilization=createmarkers
1300 $ hg commit --amend --config experimetnal.stabilization=createmarkers
1267 $ hg log -G
1301 $ hg log -G
1268 @ 4:b0551702f918 (draft) [tip ] 2
1302 @ 4:b0551702f918 (draft) [tip ] 2
1269 |
1303 |
1270 o 1:e016b03fd86f (draft) [ ] 1
1304 o 1:e016b03fd86f (draft) [ ] 1
1271 |
1305 |
1272 o 0:a78f55e5508c (draft) [ ] 0
1306 o 0:a78f55e5508c (draft) [ ] 0
1273
1307
1274 $ hg log -G --hidden
1308 $ hg log -G --hidden
1275 @ 4:b0551702f918 (draft) [tip ] 2
1309 @ 4:b0551702f918 (draft) [tip ] 2
1276 |
1310 |
1277 | x 3:f27abbcc1f77 (draft *obsolete*) [ ] temporary amend commit for e008cf283490
1311 | x 3:f27abbcc1f77 (draft *obsolete*) [ ] temporary amend commit for e008cf283490
1278 | |
1312 | |
1279 | x 2:e008cf283490 (draft *obsolete*) [ ] 2
1313 | x 2:e008cf283490 (draft *obsolete*) [ ] 2
1280 |/
1314 |/
1281 o 1:e016b03fd86f (draft) [ ] 1
1315 o 1:e016b03fd86f (draft) [ ] 1
1282 |
1316 |
1283 o 0:a78f55e5508c (draft) [ ] 0
1317 o 0:a78f55e5508c (draft) [ ] 0
1284
1318
1285
1319
1286 $ hg strip --hidden -r 2 --config extensions.strip= --config devel.strip-obsmarkers=no
1320 $ hg strip --hidden -r 2 --config extensions.strip= --config devel.strip-obsmarkers=no
1287 saved backup bundle to $TESTTMP/tmpe/issue4845/.hg/strip-backup/e008cf283490-39c978dc-backup.hg (glob)
1321 saved backup bundle to $TESTTMP/tmpe/issue4845/.hg/strip-backup/e008cf283490-39c978dc-backup.hg (glob)
1288 $ hg debugobsolete
1322 $ hg debugobsolete
1289 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (*) {'user': 'test'} (glob)
1323 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (*) {'user': 'test'} (glob)
1290 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (*) {'user': 'test'} (glob)
1324 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (*) {'user': 'test'} (glob)
1291 $ hg log -G
1325 $ hg log -G
1292 @ 2:b0551702f918 (draft) [tip ] 2
1326 @ 2:b0551702f918 (draft) [tip ] 2
1293 |
1327 |
1294 o 1:e016b03fd86f (draft) [ ] 1
1328 o 1:e016b03fd86f (draft) [ ] 1
1295 |
1329 |
1296 o 0:a78f55e5508c (draft) [ ] 0
1330 o 0:a78f55e5508c (draft) [ ] 0
1297
1331
1298 $ hg log -G --hidden
1332 $ hg log -G --hidden
1299 @ 2:b0551702f918 (draft) [tip ] 2
1333 @ 2:b0551702f918 (draft) [tip ] 2
1300 |
1334 |
1301 o 1:e016b03fd86f (draft) [ ] 1
1335 o 1:e016b03fd86f (draft) [ ] 1
1302 |
1336 |
1303 o 0:a78f55e5508c (draft) [ ] 0
1337 o 0:a78f55e5508c (draft) [ ] 0
1304
1338
1305 $ hg debugbundle .hg/strip-backup/e008cf283490-*-backup.hg
1339 $ hg debugbundle .hg/strip-backup/e008cf283490-*-backup.hg
1306 Stream params: sortdict([('Compression', 'BZ')])
1340 Stream params: sortdict([('Compression', 'BZ')])
1307 changegroup -- "sortdict([('version', '02'), ('nbchanges', '2')])"
1341 changegroup -- "sortdict([('version', '02'), ('nbchanges', '2')])"
1308 e008cf2834908e5d6b0f792a9d4b0e2272260fb8
1342 e008cf2834908e5d6b0f792a9d4b0e2272260fb8
1309 f27abbcc1f77fb409cf9160482fe619541e2d605
1343 f27abbcc1f77fb409cf9160482fe619541e2d605
1310 obsmarkers -- 'sortdict()'
1344 obsmarkers -- 'sortdict()'
1311 version: 1 (70 bytes)
1345 version: 1 (70 bytes)
1312 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1346 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1313 phase-heads -- 'sortdict()'
1347 phase-heads -- 'sortdict()'
1314 f27abbcc1f77fb409cf9160482fe619541e2d605 draft
1348 f27abbcc1f77fb409cf9160482fe619541e2d605 draft
1315
1349
1316 $ hg pull .hg/strip-backup/e008cf283490-*-backup.hg
1350 $ hg pull .hg/strip-backup/e008cf283490-*-backup.hg
1317 pulling from .hg/strip-backup/e008cf283490-39c978dc-backup.hg
1351 pulling from .hg/strip-backup/e008cf283490-39c978dc-backup.hg
1318 searching for changes
1352 searching for changes
1319 no changes found
1353 no changes found
1320 $ hg debugobsolete
1354 $ hg debugobsolete
1321 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (*) {'user': 'test'} (glob)
1355 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (*) {'user': 'test'} (glob)
1322 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (*) {'user': 'test'} (glob)
1356 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (*) {'user': 'test'} (glob)
1323 $ hg log -G
1357 $ hg log -G
1324 @ 2:b0551702f918 (draft) [tip ] 2
1358 @ 2:b0551702f918 (draft) [tip ] 2
1325 |
1359 |
1326 o 1:e016b03fd86f (draft) [ ] 1
1360 o 1:e016b03fd86f (draft) [ ] 1
1327 |
1361 |
1328 o 0:a78f55e5508c (draft) [ ] 0
1362 o 0:a78f55e5508c (draft) [ ] 0
1329
1363
1330 $ hg log -G --hidden
1364 $ hg log -G --hidden
1331 @ 2:b0551702f918 (draft) [tip ] 2
1365 @ 2:b0551702f918 (draft) [tip ] 2
1332 |
1366 |
1333 o 1:e016b03fd86f (draft) [ ] 1
1367 o 1:e016b03fd86f (draft) [ ] 1
1334 |
1368 |
1335 o 0:a78f55e5508c (draft) [ ] 0
1369 o 0:a78f55e5508c (draft) [ ] 0
1336
1370
1337
1371
1338 Testing that strip remove markers:
1372 Testing that strip remove markers:
1339
1373
1340 $ hg strip -r 1 --config extensions.strip=
1374 $ hg strip -r 1 --config extensions.strip=
1341 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
1375 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
1342 saved backup bundle to $TESTTMP/tmpe/issue4845/.hg/strip-backup/e016b03fd86f-65ede734-backup.hg (glob)
1376 saved backup bundle to $TESTTMP/tmpe/issue4845/.hg/strip-backup/e016b03fd86f-65ede734-backup.hg (glob)
1343 $ hg debugobsolete
1377 $ hg debugobsolete
1344 $ hg log -G
1378 $ hg log -G
1345 @ 0:a78f55e5508c (draft) [tip ] 0
1379 @ 0:a78f55e5508c (draft) [tip ] 0
1346
1380
1347 $ hg log -G --hidden
1381 $ hg log -G --hidden
1348 @ 0:a78f55e5508c (draft) [tip ] 0
1382 @ 0:a78f55e5508c (draft) [tip ] 0
1349
1383
1350 $ hg debugbundle .hg/strip-backup/e016b03fd86f-*-backup.hg
1384 $ hg debugbundle .hg/strip-backup/e016b03fd86f-*-backup.hg
1351 Stream params: sortdict([('Compression', 'BZ')])
1385 Stream params: sortdict([('Compression', 'BZ')])
1352 changegroup -- "sortdict([('version', '02'), ('nbchanges', '2')])"
1386 changegroup -- "sortdict([('version', '02'), ('nbchanges', '2')])"
1353 e016b03fd86fcccc54817d120b90b751aaf367d6
1387 e016b03fd86fcccc54817d120b90b751aaf367d6
1354 b0551702f918510f01ae838ab03a463054c67b46
1388 b0551702f918510f01ae838ab03a463054c67b46
1355 obsmarkers -- 'sortdict()'
1389 obsmarkers -- 'sortdict()'
1356 version: 1 (139 bytes)
1390 version: 1 (139 bytes)
1357 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1391 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1358 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1392 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1359 phase-heads -- 'sortdict()'
1393 phase-heads -- 'sortdict()'
1360 b0551702f918510f01ae838ab03a463054c67b46 draft
1394 b0551702f918510f01ae838ab03a463054c67b46 draft
1361
1395
1362 $ hg unbundle .hg/strip-backup/e016b03fd86f-*-backup.hg
1396 $ hg unbundle .hg/strip-backup/e016b03fd86f-*-backup.hg
1363 adding changesets
1397 adding changesets
1364 adding manifests
1398 adding manifests
1365 adding file changes
1399 adding file changes
1366 added 2 changesets with 2 changes to 2 files
1400 added 2 changesets with 2 changes to 2 files
1367 2 new obsolescence markers
1401 2 new obsolescence markers
1368 (run 'hg update' to get a working copy)
1402 (run 'hg update' to get a working copy)
1369 $ hg debugobsolete | sort
1403 $ hg debugobsolete | sort
1370 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (*) {'user': 'test'} (glob)
1404 e008cf2834908e5d6b0f792a9d4b0e2272260fb8 b0551702f918510f01ae838ab03a463054c67b46 0 (*) {'user': 'test'} (glob)
1371 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (*) {'user': 'test'} (glob)
1405 f27abbcc1f77fb409cf9160482fe619541e2d605 0 {e008cf2834908e5d6b0f792a9d4b0e2272260fb8} (*) {'user': 'test'} (glob)
1372 $ hg log -G
1406 $ hg log -G
1373 o 2:b0551702f918 (draft) [tip ] 2
1407 o 2:b0551702f918 (draft) [tip ] 2
1374 |
1408 |
1375 o 1:e016b03fd86f (draft) [ ] 1
1409 o 1:e016b03fd86f (draft) [ ] 1
1376 |
1410 |
1377 @ 0:a78f55e5508c (draft) [ ] 0
1411 @ 0:a78f55e5508c (draft) [ ] 0
1378
1412
1379 $ hg log -G --hidden
1413 $ hg log -G --hidden
1380 o 2:b0551702f918 (draft) [tip ] 2
1414 o 2:b0551702f918 (draft) [tip ] 2
1381 |
1415 |
1382 o 1:e016b03fd86f (draft) [ ] 1
1416 o 1:e016b03fd86f (draft) [ ] 1
1383 |
1417 |
1384 @ 0:a78f55e5508c (draft) [ ] 0
1418 @ 0:a78f55e5508c (draft) [ ] 0
1385
1419
1386 Test that 'hg debugobsolete --index --rev' can show indices of obsmarkers when
1420 Test that 'hg debugobsolete --index --rev' can show indices of obsmarkers when
1387 only a subset of those are displayed (because of --rev option)
1421 only a subset of those are displayed (because of --rev option)
1388 $ hg init doindexrev
1422 $ hg init doindexrev
1389 $ cd doindexrev
1423 $ cd doindexrev
1390 $ echo a > a
1424 $ echo a > a
1391 $ hg ci -Am a
1425 $ hg ci -Am a
1392 adding a
1426 adding a
1393 $ hg ci --amend -m aa
1427 $ hg ci --amend -m aa
1394 $ echo b > b
1428 $ echo b > b
1395 $ hg ci -Am b
1429 $ hg ci -Am b
1396 adding b
1430 adding b
1397 $ hg ci --amend -m bb
1431 $ hg ci --amend -m bb
1398 $ echo c > c
1432 $ echo c > c
1399 $ hg ci -Am c
1433 $ hg ci -Am c
1400 adding c
1434 adding c
1401 $ hg ci --amend -m cc
1435 $ hg ci --amend -m cc
1402 $ echo d > d
1436 $ echo d > d
1403 $ hg ci -Am d
1437 $ hg ci -Am d
1404 adding d
1438 adding d
1405 $ hg ci --amend -m dd --config experimental.stabilization.track-operation=1
1439 $ hg ci --amend -m dd --config experimental.stabilization.track-operation=1
1406 $ hg debugobsolete --index --rev "3+7"
1440 $ hg debugobsolete --index --rev "3+7"
1407 1 6fdef60fcbabbd3d50e9b9cbc2a240724b91a5e1 d27fb9b066076fd921277a4b9e8b9cb48c95bc6a 0 \(.*\) {'user': 'test'} (re)
1441 1 6fdef60fcbabbd3d50e9b9cbc2a240724b91a5e1 d27fb9b066076fd921277a4b9e8b9cb48c95bc6a 0 \(.*\) {'user': 'test'} (re)
1408 3 4715cf767440ed891755448016c2b8cf70760c30 7ae79c5d60f049c7b0dd02f5f25b9d60aaf7b36d 0 \(.*\) {'operation': 'amend', 'user': 'test'} (re)
1442 3 4715cf767440ed891755448016c2b8cf70760c30 7ae79c5d60f049c7b0dd02f5f25b9d60aaf7b36d 0 \(.*\) {'operation': 'amend', 'user': 'test'} (re)
1409 $ hg debugobsolete --index --rev "3+7" -Tjson
1443 $ hg debugobsolete --index --rev "3+7" -Tjson
1410 [
1444 [
1411 {
1445 {
1412 "date": [0.0, 0],
1446 "date": [0.0, 0],
1413 "flag": 0,
1447 "flag": 0,
1414 "index": 1,
1448 "index": 1,
1415 "metadata": {"user": "test"},
1449 "metadata": {"user": "test"},
1416 "precnode": "6fdef60fcbabbd3d50e9b9cbc2a240724b91a5e1",
1450 "precnode": "6fdef60fcbabbd3d50e9b9cbc2a240724b91a5e1",
1417 "succnodes": ["d27fb9b066076fd921277a4b9e8b9cb48c95bc6a"]
1451 "succnodes": ["d27fb9b066076fd921277a4b9e8b9cb48c95bc6a"]
1418 },
1452 },
1419 {
1453 {
1420 "date": [0.0, 0],
1454 "date": [0.0, 0],
1421 "flag": 0,
1455 "flag": 0,
1422 "index": 3,
1456 "index": 3,
1423 "metadata": {"operation": "amend", "user": "test"},
1457 "metadata": {"operation": "amend", "user": "test"},
1424 "precnode": "4715cf767440ed891755448016c2b8cf70760c30",
1458 "precnode": "4715cf767440ed891755448016c2b8cf70760c30",
1425 "succnodes": ["7ae79c5d60f049c7b0dd02f5f25b9d60aaf7b36d"]
1459 "succnodes": ["7ae79c5d60f049c7b0dd02f5f25b9d60aaf7b36d"]
1426 }
1460 }
1427 ]
1461 ]
1428
1462
1429 Test the --delete option of debugobsolete command
1463 Test the --delete option of debugobsolete command
1430 $ hg debugobsolete --index
1464 $ hg debugobsolete --index
1431 0 cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b f9bd49731b0b175e42992a3c8fa6c678b2bc11f1 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1465 0 cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b f9bd49731b0b175e42992a3c8fa6c678b2bc11f1 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1432 1 6fdef60fcbabbd3d50e9b9cbc2a240724b91a5e1 d27fb9b066076fd921277a4b9e8b9cb48c95bc6a 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1466 1 6fdef60fcbabbd3d50e9b9cbc2a240724b91a5e1 d27fb9b066076fd921277a4b9e8b9cb48c95bc6a 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1433 2 1ab51af8f9b41ef8c7f6f3312d4706d870b1fb74 29346082e4a9e27042b62d2da0e2de211c027621 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1467 2 1ab51af8f9b41ef8c7f6f3312d4706d870b1fb74 29346082e4a9e27042b62d2da0e2de211c027621 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1434 3 4715cf767440ed891755448016c2b8cf70760c30 7ae79c5d60f049c7b0dd02f5f25b9d60aaf7b36d 0 (Thu Jan 01 00:00:00 1970 +0000) {'operation': 'amend', 'user': 'test'}
1468 3 4715cf767440ed891755448016c2b8cf70760c30 7ae79c5d60f049c7b0dd02f5f25b9d60aaf7b36d 0 (Thu Jan 01 00:00:00 1970 +0000) {'operation': 'amend', 'user': 'test'}
1435 $ hg debugobsolete --delete 1 --delete 3
1469 $ hg debugobsolete --delete 1 --delete 3
1436 deleted 2 obsolescence markers
1470 deleted 2 obsolescence markers
1437 $ hg debugobsolete
1471 $ hg debugobsolete
1438 cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b f9bd49731b0b175e42992a3c8fa6c678b2bc11f1 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1472 cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b f9bd49731b0b175e42992a3c8fa6c678b2bc11f1 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1439 1ab51af8f9b41ef8c7f6f3312d4706d870b1fb74 29346082e4a9e27042b62d2da0e2de211c027621 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1473 1ab51af8f9b41ef8c7f6f3312d4706d870b1fb74 29346082e4a9e27042b62d2da0e2de211c027621 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1440
1474
1441 Test adding changeset after obsmarkers affecting it
1475 Test adding changeset after obsmarkers affecting it
1442 (eg: during pull, or unbundle)
1476 (eg: during pull, or unbundle)
1443
1477
1444 $ mkcommit e
1478 $ mkcommit e
1445 $ hg bundle -r . --base .~1 ../bundle-2.hg
1479 $ hg bundle -r . --base .~1 ../bundle-2.hg
1446 1 changesets found
1480 1 changesets found
1447 $ getid .
1481 $ getid .
1448 $ hg --config extensions.strip= strip -r .
1482 $ hg --config extensions.strip= strip -r .
1449 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1483 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1450 saved backup bundle to $TESTTMP/tmpe/issue4845/doindexrev/.hg/strip-backup/9bc153528424-ee80edd4-backup.hg (glob)
1484 saved backup bundle to $TESTTMP/tmpe/issue4845/doindexrev/.hg/strip-backup/9bc153528424-ee80edd4-backup.hg (glob)
1451 $ hg debugobsolete 9bc153528424ea266d13e57f9ff0d799dfe61e4b
1485 $ hg debugobsolete 9bc153528424ea266d13e57f9ff0d799dfe61e4b
1452 $ hg unbundle ../bundle-2.hg
1486 $ hg unbundle ../bundle-2.hg
1453 adding changesets
1487 adding changesets
1454 adding manifests
1488 adding manifests
1455 adding file changes
1489 adding file changes
1456 added 1 changesets with 1 changes to 1 files
1490 added 1 changesets with 1 changes to 1 files
1457 (run 'hg update' to get a working copy)
1491 (run 'hg update' to get a working copy)
1458 $ hg log -G
1492 $ hg log -G
1459 @ 7:7ae79c5d60f0 (draft) [tip ] dd
1493 @ 7:7ae79c5d60f0 (draft) [tip ] dd
1460 |
1494 |
1461 | o 6:4715cf767440 (draft) [ ] d
1495 | o 6:4715cf767440 (draft) [ ] d
1462 |/
1496 |/
1463 o 5:29346082e4a9 (draft) [ ] cc
1497 o 5:29346082e4a9 (draft) [ ] cc
1464 |
1498 |
1465 o 3:d27fb9b06607 (draft) [ ] bb
1499 o 3:d27fb9b06607 (draft) [ ] bb
1466 |
1500 |
1467 | o 2:6fdef60fcbab (draft) [ ] b
1501 | o 2:6fdef60fcbab (draft) [ ] b
1468 |/
1502 |/
1469 o 1:f9bd49731b0b (draft) [ ] aa
1503 o 1:f9bd49731b0b (draft) [ ] aa
1470
1504
1471
1505
1472 $ cd ..
1506 $ cd ..
General Comments 0
You need to be logged in to leave comments. Login now