Show More
@@ -1,748 +1,748 b'' | |||
|
1 | 1 | $ cat >> $HGRCPATH << EOF |
|
2 | 2 | > [phases] |
|
3 | 3 | > # public changeset are not obsolete |
|
4 | 4 | > publish=false |
|
5 | 5 | > [ui] |
|
6 | 6 | > logtemplate="{rev}:{node|short} ({phase}) [{tags} {bookmarks}] {desc|firstline}\n" |
|
7 | 7 | > EOF |
|
8 | 8 | $ mkcommit() { |
|
9 | 9 | > echo "$1" > "$1" |
|
10 | 10 | > hg add "$1" |
|
11 | 11 | > hg ci -m "add $1" |
|
12 | 12 | > } |
|
13 | 13 | $ getid() { |
|
14 | 14 | > hg id --debug --hidden -ir "desc('$1')" |
|
15 | 15 | > } |
|
16 | 16 | |
|
17 | 17 | $ cat > debugkeys.py <<EOF |
|
18 | 18 | > def reposetup(ui, repo): |
|
19 | 19 | > class debugkeysrepo(repo.__class__): |
|
20 | 20 | > def listkeys(self, namespace): |
|
21 | 21 | > ui.write('listkeys %s\n' % (namespace,)) |
|
22 | 22 | > return super(debugkeysrepo, self).listkeys(namespace) |
|
23 | 23 | > |
|
24 | 24 | > if repo.local(): |
|
25 | 25 | > repo.__class__ = debugkeysrepo |
|
26 | 26 | > EOF |
|
27 | 27 | |
|
28 | 28 | $ hg init tmpa |
|
29 | 29 | $ cd tmpa |
|
30 | 30 | $ mkcommit kill_me |
|
31 | 31 | |
|
32 | 32 | Checking that the feature is properly disabled |
|
33 | 33 | |
|
34 | 34 | $ hg debugobsolete -d '0 0' `getid kill_me` -u babar |
|
35 | 35 | abort: obsolete feature is not enabled on this repo |
|
36 | 36 | [255] |
|
37 | 37 | |
|
38 | 38 | Enabling it |
|
39 | 39 | |
|
40 | 40 | $ cat > ../obs.py << EOF |
|
41 | 41 | > import mercurial.obsolete |
|
42 | 42 | > mercurial.obsolete._enabled = True |
|
43 | 43 | > EOF |
|
44 | 44 | $ echo '[extensions]' >> $HGRCPATH |
|
45 | 45 | $ echo "obs=${TESTTMP}/obs.py" >> $HGRCPATH |
|
46 | 46 | |
|
47 | 47 | Killing a single changeset without replacement |
|
48 | 48 | |
|
49 | 49 | $ hg debugobsolete 0 |
|
50 | 50 | abort: changeset references must be full hexadecimal node identifiers |
|
51 | 51 | [255] |
|
52 | 52 | $ hg debugobsolete '00' |
|
53 | 53 | abort: changeset references must be full hexadecimal node identifiers |
|
54 | 54 | [255] |
|
55 | 55 | $ hg debugobsolete -d '0 0' `getid kill_me` -u babar |
|
56 | 56 | $ hg debugobsolete |
|
57 | 57 | 97b7c2d76b1845ed3eb988cd612611e72406cef0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'babar'} |
|
58 | 58 | |
|
59 | 59 | (test that mercurial is not confused) |
|
60 | 60 | |
|
61 | 61 | $ hg up null --quiet # having 0 as parent prevents it to be hidden |
|
62 | 62 | $ hg tip |
|
63 | 63 | -1:000000000000 (public) [tip ] |
|
64 | 64 | $ hg up --hidden tip --quiet |
|
65 | 65 | |
|
66 | 66 | Killing a single changeset with itself should fail |
|
67 | 67 | (simple local safeguard) |
|
68 | 68 | |
|
69 | 69 | $ hg debugobsolete `getid kill_me` `getid kill_me` |
|
70 | 70 | abort: bad obsmarker input: in-marker cycle with 97b7c2d76b1845ed3eb988cd612611e72406cef0 |
|
71 | 71 | [255] |
|
72 | 72 | |
|
73 | 73 | $ cd .. |
|
74 | 74 | |
|
75 | 75 | Killing a single changeset with replacement |
|
76 | 76 | |
|
77 | 77 | $ hg init tmpb |
|
78 | 78 | $ cd tmpb |
|
79 | 79 | $ mkcommit a |
|
80 | 80 | $ mkcommit b |
|
81 | 81 | $ mkcommit original_c |
|
82 | 82 | $ hg up "desc('b')" |
|
83 | 83 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
84 | 84 | $ mkcommit new_c |
|
85 | 85 | created new head |
|
86 | 86 | $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden |
|
87 | $ hg debugobsolete --flag 12 `getid original_c` `getid new_c` -d '56 12' | |
|
87 | $ hg debugobsolete --flag 12 `getid original_c` `getid new_c` -d '56 120' | |
|
88 | 88 | $ hg log -r 'hidden()' --template '{rev}:{node|short} {desc}\n' --hidden |
|
89 | 89 | 2:245bde4270cd add original_c |
|
90 | 90 | $ hg debugrevlog -cd |
|
91 | 91 | # rev p1rev p2rev start end deltastart base p1 p2 rawsize totalsize compression heads chainlen |
|
92 | 92 | 0 -1 -1 0 59 0 0 0 0 58 58 0 1 0 |
|
93 | 93 | 1 0 -1 59 118 59 59 0 0 58 116 0 1 0 |
|
94 | 94 | 2 1 -1 118 204 59 59 59 0 76 192 0 1 1 |
|
95 | 95 | 3 1 -1 204 271 204 204 59 0 66 258 0 2 0 |
|
96 | 96 | $ hg debugobsolete |
|
97 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
97 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
98 | 98 | |
|
99 | 99 | do it again (it read the obsstore before adding new changeset) |
|
100 | 100 | |
|
101 | 101 | $ hg up '.^' |
|
102 | 102 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
103 | 103 | $ mkcommit new_2_c |
|
104 | 104 | created new head |
|
105 | 105 | $ hg debugobsolete -d '1337 0' `getid new_c` `getid new_2_c` |
|
106 | 106 | $ hg debugobsolete |
|
107 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
107 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
108 | 108 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
109 | 109 | |
|
110 | 110 | Register two markers with a missing node |
|
111 | 111 | |
|
112 | 112 | $ hg up '.^' |
|
113 | 113 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
114 | 114 | $ mkcommit new_3_c |
|
115 | 115 | created new head |
|
116 | 116 | $ hg debugobsolete -d '1338 0' `getid new_2_c` 1337133713371337133713371337133713371337 |
|
117 | 117 | $ hg debugobsolete -d '1339 0' 1337133713371337133713371337133713371337 `getid new_3_c` |
|
118 | 118 | $ hg debugobsolete |
|
119 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
119 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
120 | 120 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
121 | 121 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
122 | 122 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
123 | 123 | |
|
124 | 124 | Refuse pathological nullid successors |
|
125 | 125 | $ hg debugobsolete -d '9001 0' 1337133713371337133713371337133713371337 0000000000000000000000000000000000000000 |
|
126 | 126 | transaction abort! |
|
127 | 127 | rollback completed |
|
128 | 128 | abort: bad obsolescence marker detected: invalid successors nullid |
|
129 | 129 | [255] |
|
130 | 130 | |
|
131 | 131 | Check that graphlog detect that a changeset is obsolete: |
|
132 | 132 | |
|
133 | 133 | $ hg log -G |
|
134 | 134 | @ 5:5601fb93a350 (draft) [tip ] add new_3_c |
|
135 | 135 | | |
|
136 | 136 | o 1:7c3bad9141dc (draft) [ ] add b |
|
137 | 137 | | |
|
138 | 138 | o 0:1f0dee641bb7 (draft) [ ] add a |
|
139 | 139 | |
|
140 | 140 | |
|
141 | 141 | check that heads does not report them |
|
142 | 142 | |
|
143 | 143 | $ hg heads |
|
144 | 144 | 5:5601fb93a350 (draft) [tip ] add new_3_c |
|
145 | 145 | $ hg heads --hidden |
|
146 | 146 | 5:5601fb93a350 (draft) [tip ] add new_3_c |
|
147 | 147 | 4:ca819180edb9 (draft) [ ] add new_2_c |
|
148 | 148 | 3:cdbce2fbb163 (draft) [ ] add new_c |
|
149 | 149 | 2:245bde4270cd (draft) [ ] add original_c |
|
150 | 150 | |
|
151 | 151 | |
|
152 | 152 | check that summary does not report them |
|
153 | 153 | |
|
154 | 154 | $ hg init ../sink |
|
155 | 155 | $ echo '[paths]' >> .hg/hgrc |
|
156 | 156 | $ echo 'default=../sink' >> .hg/hgrc |
|
157 | 157 | $ hg summary --remote |
|
158 | 158 | parent: 5:5601fb93a350 tip |
|
159 | 159 | add new_3_c |
|
160 | 160 | branch: default |
|
161 | 161 | commit: (clean) |
|
162 | 162 | update: (current) |
|
163 | 163 | remote: 3 outgoing |
|
164 | 164 | |
|
165 | 165 | $ hg summary --remote --hidden |
|
166 | 166 | parent: 5:5601fb93a350 tip |
|
167 | 167 | add new_3_c |
|
168 | 168 | branch: default |
|
169 | 169 | commit: (clean) |
|
170 | 170 | update: 3 new changesets, 4 branch heads (merge) |
|
171 | 171 | remote: 3 outgoing |
|
172 | 172 | |
|
173 | 173 | check that various commands work well with filtering |
|
174 | 174 | |
|
175 | 175 | $ hg tip |
|
176 | 176 | 5:5601fb93a350 (draft) [tip ] add new_3_c |
|
177 | 177 | $ hg log -r 6 |
|
178 | 178 | abort: unknown revision '6'! |
|
179 | 179 | [255] |
|
180 | 180 | $ hg log -r 4 |
|
181 | 181 | abort: unknown revision '4'! |
|
182 | 182 | [255] |
|
183 | 183 | |
|
184 | 184 | Check that public changeset are not accounted as obsolete: |
|
185 | 185 | |
|
186 | 186 | $ hg --hidden phase --public 2 |
|
187 | 187 | $ hg log -G |
|
188 | 188 | @ 5:5601fb93a350 (draft) [tip ] add new_3_c |
|
189 | 189 | | |
|
190 | 190 | | o 2:245bde4270cd (public) [ ] add original_c |
|
191 | 191 | |/ |
|
192 | 192 | o 1:7c3bad9141dc (public) [ ] add b |
|
193 | 193 | | |
|
194 | 194 | o 0:1f0dee641bb7 (public) [ ] add a |
|
195 | 195 | |
|
196 | 196 | |
|
197 | 197 | And that bumped changeset are detected |
|
198 | 198 | -------------------------------------- |
|
199 | 199 | |
|
200 | 200 | If we didn't filtered obsolete changesets out, 3 and 4 would show up too. Also |
|
201 | 201 | note that the bumped changeset (5:5601fb93a350) is not a direct successor of |
|
202 | 202 | the public changeset |
|
203 | 203 | |
|
204 | 204 | $ hg log --hidden -r 'bumped()' |
|
205 | 205 | 5:5601fb93a350 (draft) [tip ] add new_3_c |
|
206 | 206 | |
|
207 | 207 | And that we can't push bumped changeset |
|
208 | 208 | |
|
209 | 209 | $ hg push ../tmpa -r 0 --force #(make repo related) |
|
210 | 210 | pushing to ../tmpa |
|
211 | 211 | searching for changes |
|
212 | 212 | warning: repository is unrelated |
|
213 | 213 | adding changesets |
|
214 | 214 | adding manifests |
|
215 | 215 | adding file changes |
|
216 | 216 | added 1 changesets with 1 changes to 1 files (+1 heads) |
|
217 | 217 | $ hg push ../tmpa |
|
218 | 218 | pushing to ../tmpa |
|
219 | 219 | searching for changes |
|
220 | 220 | abort: push includes bumped changeset: 5601fb93a350! |
|
221 | 221 | [255] |
|
222 | 222 | |
|
223 | 223 | Fixing "bumped" situation |
|
224 | 224 | We need to create a clone of 5 and add a special marker with a flag |
|
225 | 225 | |
|
226 | 226 | $ hg up '5^' |
|
227 | 227 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
228 | 228 | $ hg revert -ar 5 |
|
229 | 229 | adding new_3_c |
|
230 | 230 | $ hg ci -m 'add n3w_3_c' |
|
231 | 231 | created new head |
|
232 | 232 | $ hg debugobsolete -d '1338 0' --flags 1 `getid new_3_c` `getid n3w_3_c` |
|
233 | 233 | $ hg log -r 'bumped()' |
|
234 | 234 | $ hg log -G |
|
235 | 235 | @ 6:6f9641995072 (draft) [tip ] add n3w_3_c |
|
236 | 236 | | |
|
237 | 237 | | o 2:245bde4270cd (public) [ ] add original_c |
|
238 | 238 | |/ |
|
239 | 239 | o 1:7c3bad9141dc (public) [ ] add b |
|
240 | 240 | | |
|
241 | 241 | o 0:1f0dee641bb7 (public) [ ] add a |
|
242 | 242 | |
|
243 | 243 | |
|
244 | 244 | |
|
245 | 245 | |
|
246 | 246 | $ cd .. |
|
247 | 247 | |
|
248 | 248 | Exchange Test |
|
249 | 249 | ============================ |
|
250 | 250 | |
|
251 | 251 | Destination repo does not have any data |
|
252 | 252 | --------------------------------------- |
|
253 | 253 | |
|
254 | 254 | Simple incoming test |
|
255 | 255 | |
|
256 | 256 | $ hg init tmpc |
|
257 | 257 | $ cd tmpc |
|
258 | 258 | $ hg incoming ../tmpb |
|
259 | 259 | comparing with ../tmpb |
|
260 | 260 | 0:1f0dee641bb7 (public) [ ] add a |
|
261 | 261 | 1:7c3bad9141dc (public) [ ] add b |
|
262 | 262 | 2:245bde4270cd (public) [ ] add original_c |
|
263 | 263 | 6:6f9641995072 (draft) [tip ] add n3w_3_c |
|
264 | 264 | |
|
265 | 265 | Try to pull markers |
|
266 | 266 | (extinct changeset are excluded but marker are pushed) |
|
267 | 267 | |
|
268 | 268 | $ hg pull ../tmpb |
|
269 | 269 | pulling from ../tmpb |
|
270 | 270 | requesting all changes |
|
271 | 271 | adding changesets |
|
272 | 272 | adding manifests |
|
273 | 273 | adding file changes |
|
274 | 274 | added 4 changesets with 4 changes to 4 files (+1 heads) |
|
275 | 275 | (run 'hg heads' to see heads, 'hg merge' to merge) |
|
276 | 276 | $ hg debugobsolete |
|
277 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
277 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
278 | 278 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
279 | 279 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
280 | 280 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
281 | 281 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
282 | 282 | |
|
283 | 283 | Rollback//Transaction support |
|
284 | 284 | |
|
285 | 285 | $ hg debugobsolete -d '1340 0' aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb |
|
286 | 286 | $ hg debugobsolete |
|
287 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
287 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
288 | 288 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
289 | 289 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
290 | 290 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
291 | 291 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
292 | 292 | aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb 0 (Thu Jan 01 00:22:20 1970 +0000) {'user': 'test'} |
|
293 | 293 | $ hg rollback -n |
|
294 | 294 | repository tip rolled back to revision 3 (undo debugobsolete) |
|
295 | 295 | $ hg rollback |
|
296 | 296 | repository tip rolled back to revision 3 (undo debugobsolete) |
|
297 | 297 | $ hg debugobsolete |
|
298 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
298 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
299 | 299 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
300 | 300 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
301 | 301 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
302 | 302 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
303 | 303 | |
|
304 | 304 | $ cd .. |
|
305 | 305 | |
|
306 | 306 | Try to push markers |
|
307 | 307 | |
|
308 | 308 | $ hg init tmpd |
|
309 | 309 | $ hg -R tmpb push tmpd |
|
310 | 310 | pushing to tmpd |
|
311 | 311 | searching for changes |
|
312 | 312 | adding changesets |
|
313 | 313 | adding manifests |
|
314 | 314 | adding file changes |
|
315 | 315 | added 4 changesets with 4 changes to 4 files (+1 heads) |
|
316 | 316 | $ hg -R tmpd debugobsolete | sort |
|
317 | 317 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
318 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
318 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
319 | 319 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
320 | 320 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
321 | 321 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
322 | 322 | |
|
323 | 323 | Check obsolete keys are exchanged only if source has an obsolete store |
|
324 | 324 | |
|
325 | 325 | $ hg init empty |
|
326 | 326 | $ hg --config extensions.debugkeys=debugkeys.py -R empty push tmpd |
|
327 | 327 | pushing to tmpd |
|
328 | 328 | listkeys phases |
|
329 | 329 | listkeys bookmarks |
|
330 | 330 | no changes found |
|
331 | 331 | listkeys phases |
|
332 | 332 | [1] |
|
333 | 333 | |
|
334 | 334 | clone support |
|
335 | 335 | (markers are copied and extinct changesets are included to allow hardlinks) |
|
336 | 336 | |
|
337 | 337 | $ hg clone tmpb clone-dest |
|
338 | 338 | updating to branch default |
|
339 | 339 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
340 | 340 | $ hg -R clone-dest log -G --hidden |
|
341 | 341 | @ 6:6f9641995072 (draft) [tip ] add n3w_3_c |
|
342 | 342 | | |
|
343 | 343 | | x 5:5601fb93a350 (draft) [ ] add new_3_c |
|
344 | 344 | |/ |
|
345 | 345 | | x 4:ca819180edb9 (draft) [ ] add new_2_c |
|
346 | 346 | |/ |
|
347 | 347 | | x 3:cdbce2fbb163 (draft) [ ] add new_c |
|
348 | 348 | |/ |
|
349 | 349 | | o 2:245bde4270cd (public) [ ] add original_c |
|
350 | 350 | |/ |
|
351 | 351 | o 1:7c3bad9141dc (public) [ ] add b |
|
352 | 352 | | |
|
353 | 353 | o 0:1f0dee641bb7 (public) [ ] add a |
|
354 | 354 | |
|
355 | 355 | $ hg -R clone-dest debugobsolete |
|
356 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
356 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
357 | 357 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
358 | 358 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
359 | 359 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
360 | 360 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
361 | 361 | |
|
362 | 362 | |
|
363 | 363 | Destination repo have existing data |
|
364 | 364 | --------------------------------------- |
|
365 | 365 | |
|
366 | 366 | On pull |
|
367 | 367 | |
|
368 | 368 | $ hg init tmpe |
|
369 | 369 | $ cd tmpe |
|
370 | 370 | $ hg debugobsolete -d '1339 0' 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 |
|
371 | 371 | $ hg pull ../tmpb |
|
372 | 372 | pulling from ../tmpb |
|
373 | 373 | requesting all changes |
|
374 | 374 | adding changesets |
|
375 | 375 | adding manifests |
|
376 | 376 | adding file changes |
|
377 | 377 | added 4 changesets with 4 changes to 4 files (+1 heads) |
|
378 | 378 | (run 'hg heads' to see heads, 'hg merge' to merge) |
|
379 | 379 | $ hg debugobsolete |
|
380 | 380 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
381 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
381 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
382 | 382 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
383 | 383 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
384 | 384 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
385 | 385 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
386 | 386 | |
|
387 | 387 | |
|
388 | 388 | On push |
|
389 | 389 | |
|
390 | 390 | $ hg push ../tmpc |
|
391 | 391 | pushing to ../tmpc |
|
392 | 392 | searching for changes |
|
393 | 393 | no changes found |
|
394 | 394 | [1] |
|
395 | 395 | $ hg -R ../tmpc debugobsolete |
|
396 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
396 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
397 | 397 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
398 | 398 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
399 | 399 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
400 | 400 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
401 | 401 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
402 | 402 | |
|
403 | 403 | detect outgoing obsolete and unstable |
|
404 | 404 | --------------------------------------- |
|
405 | 405 | |
|
406 | 406 | |
|
407 | 407 | $ hg log -G |
|
408 | 408 | o 3:6f9641995072 (draft) [tip ] add n3w_3_c |
|
409 | 409 | | |
|
410 | 410 | | o 2:245bde4270cd (public) [ ] add original_c |
|
411 | 411 | |/ |
|
412 | 412 | o 1:7c3bad9141dc (public) [ ] add b |
|
413 | 413 | | |
|
414 | 414 | o 0:1f0dee641bb7 (public) [ ] add a |
|
415 | 415 | |
|
416 | 416 | $ hg up 'desc("n3w_3_c")' |
|
417 | 417 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
418 | 418 | $ mkcommit original_d |
|
419 | 419 | $ mkcommit original_e |
|
420 | 420 | $ hg debugobsolete --record-parents `getid original_d` -d '0 0' |
|
421 | 421 | $ hg debugobsolete | grep `getid original_d` |
|
422 | 422 | 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
423 | 423 | $ hg log -r 'obsolete()' |
|
424 | 424 | 4:94b33453f93b (draft) [ ] add original_d |
|
425 | 425 | $ hg log -G -r '::unstable()' |
|
426 | 426 | @ 5:cda648ca50f5 (draft) [tip ] add original_e |
|
427 | 427 | | |
|
428 | 428 | x 4:94b33453f93b (draft) [ ] add original_d |
|
429 | 429 | | |
|
430 | 430 | o 3:6f9641995072 (draft) [ ] add n3w_3_c |
|
431 | 431 | | |
|
432 | 432 | o 1:7c3bad9141dc (public) [ ] add b |
|
433 | 433 | | |
|
434 | 434 | o 0:1f0dee641bb7 (public) [ ] add a |
|
435 | 435 | |
|
436 | 436 | |
|
437 | 437 | refuse to push obsolete changeset |
|
438 | 438 | |
|
439 | 439 | $ hg push ../tmpc/ -r 'desc("original_d")' |
|
440 | 440 | pushing to ../tmpc/ |
|
441 | 441 | searching for changes |
|
442 | 442 | abort: push includes obsolete changeset: 94b33453f93b! |
|
443 | 443 | [255] |
|
444 | 444 | |
|
445 | 445 | refuse to push unstable changeset |
|
446 | 446 | |
|
447 | 447 | $ hg push ../tmpc/ |
|
448 | 448 | pushing to ../tmpc/ |
|
449 | 449 | searching for changes |
|
450 | 450 | abort: push includes unstable changeset: cda648ca50f5! |
|
451 | 451 | [255] |
|
452 | 452 | |
|
453 | 453 | Test that extinct changeset are properly detected |
|
454 | 454 | |
|
455 | 455 | $ hg log -r 'extinct()' |
|
456 | 456 | |
|
457 | 457 | Don't try to push extinct changeset |
|
458 | 458 | |
|
459 | 459 | $ hg init ../tmpf |
|
460 | 460 | $ hg out ../tmpf |
|
461 | 461 | comparing with ../tmpf |
|
462 | 462 | searching for changes |
|
463 | 463 | 0:1f0dee641bb7 (public) [ ] add a |
|
464 | 464 | 1:7c3bad9141dc (public) [ ] add b |
|
465 | 465 | 2:245bde4270cd (public) [ ] add original_c |
|
466 | 466 | 3:6f9641995072 (draft) [ ] add n3w_3_c |
|
467 | 467 | 4:94b33453f93b (draft) [ ] add original_d |
|
468 | 468 | 5:cda648ca50f5 (draft) [tip ] add original_e |
|
469 | 469 | $ hg push ../tmpf -f # -f because be push unstable too |
|
470 | 470 | pushing to ../tmpf |
|
471 | 471 | searching for changes |
|
472 | 472 | adding changesets |
|
473 | 473 | adding manifests |
|
474 | 474 | adding file changes |
|
475 | 475 | added 6 changesets with 6 changes to 6 files (+1 heads) |
|
476 | 476 | |
|
477 | 477 | no warning displayed |
|
478 | 478 | |
|
479 | 479 | $ hg push ../tmpf |
|
480 | 480 | pushing to ../tmpf |
|
481 | 481 | searching for changes |
|
482 | 482 | no changes found |
|
483 | 483 | [1] |
|
484 | 484 | |
|
485 | 485 | Do not warn about new head when the new head is a successors of a remote one |
|
486 | 486 | |
|
487 | 487 | $ hg log -G |
|
488 | 488 | @ 5:cda648ca50f5 (draft) [tip ] add original_e |
|
489 | 489 | | |
|
490 | 490 | x 4:94b33453f93b (draft) [ ] add original_d |
|
491 | 491 | | |
|
492 | 492 | o 3:6f9641995072 (draft) [ ] add n3w_3_c |
|
493 | 493 | | |
|
494 | 494 | | o 2:245bde4270cd (public) [ ] add original_c |
|
495 | 495 | |/ |
|
496 | 496 | o 1:7c3bad9141dc (public) [ ] add b |
|
497 | 497 | | |
|
498 | 498 | o 0:1f0dee641bb7 (public) [ ] add a |
|
499 | 499 | |
|
500 | 500 | $ hg up -q 'desc(n3w_3_c)' |
|
501 | 501 | $ mkcommit obsolete_e |
|
502 | 502 | created new head |
|
503 | 503 | $ hg debugobsolete `getid 'original_e'` `getid 'obsolete_e'` |
|
504 | 504 | $ hg outgoing ../tmpf # parasite hg outgoing testin |
|
505 | 505 | comparing with ../tmpf |
|
506 | 506 | searching for changes |
|
507 | 507 | 6:3de5eca88c00 (draft) [tip ] add obsolete_e |
|
508 | 508 | $ hg push ../tmpf |
|
509 | 509 | pushing to ../tmpf |
|
510 | 510 | searching for changes |
|
511 | 511 | adding changesets |
|
512 | 512 | adding manifests |
|
513 | 513 | adding file changes |
|
514 | 514 | added 1 changesets with 1 changes to 1 files (+1 heads) |
|
515 | 515 | |
|
516 | 516 | test relevance computation |
|
517 | 517 | --------------------------------------- |
|
518 | 518 | |
|
519 | 519 | Checking simple case of "marker relevance". |
|
520 | 520 | |
|
521 | 521 | |
|
522 | 522 | Reminder of the repo situation |
|
523 | 523 | |
|
524 | 524 | $ hg log --hidden --graph |
|
525 | 525 | @ 6:3de5eca88c00 (draft) [tip ] add obsolete_e |
|
526 | 526 | | |
|
527 | 527 | | x 5:cda648ca50f5 (draft) [ ] add original_e |
|
528 | 528 | | | |
|
529 | 529 | | x 4:94b33453f93b (draft) [ ] add original_d |
|
530 | 530 | |/ |
|
531 | 531 | o 3:6f9641995072 (draft) [ ] add n3w_3_c |
|
532 | 532 | | |
|
533 | 533 | | o 2:245bde4270cd (public) [ ] add original_c |
|
534 | 534 | |/ |
|
535 | 535 | o 1:7c3bad9141dc (public) [ ] add b |
|
536 | 536 | | |
|
537 | 537 | o 0:1f0dee641bb7 (public) [ ] add a |
|
538 | 538 | |
|
539 | 539 | |
|
540 | 540 | List of all markers |
|
541 | 541 | |
|
542 | 542 | $ hg debugobsolete |
|
543 | 543 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
544 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
544 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
545 | 545 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
546 | 546 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
547 | 547 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
548 | 548 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
549 | 549 | 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
550 | 550 | cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test'} (glob) |
|
551 | 551 | |
|
552 | 552 | List of changesets with no chain |
|
553 | 553 | |
|
554 | 554 | $ hg debugobsolete --hidden --rev ::2 |
|
555 | 555 | |
|
556 | 556 | List of changesets that are included on marker chain |
|
557 | 557 | |
|
558 | 558 | $ hg debugobsolete --hidden --rev 6 |
|
559 | 559 | cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test'} (glob) |
|
560 | 560 | |
|
561 | 561 | List of changesets with a longer chain, (including a pruned children) |
|
562 | 562 | |
|
563 | 563 | $ hg debugobsolete --hidden --rev 3 |
|
564 | 564 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
565 | 565 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
566 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
566 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
567 | 567 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
568 | 568 | 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
569 | 569 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
570 | 570 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
571 | 571 | |
|
572 | 572 | List of both |
|
573 | 573 | |
|
574 | 574 | $ hg debugobsolete --hidden --rev 3::6 |
|
575 | 575 | 1337133713371337133713371337133713371337 5601fb93a350734d935195fee37f4054c529ff39 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
576 | 576 | 1339133913391339133913391339133913391339 ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:19 1970 +0000) {'user': 'test'} |
|
577 |
245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C ( |
|
|
577 | 245bde4270cd1072a27757984f9cda8ba26f08ca cdbce2fbb16313928851e97e0d85413f3f7eb77f C (Wed Dec 31 23:58:56 1969 -0002) {'user': 'test'} | |
|
578 | 578 | 5601fb93a350734d935195fee37f4054c529ff39 6f96419950729f3671185b847352890f074f7557 1 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
579 | 579 | 94b33453f93bdb8d457ef9b770851a618bf413e1 0 {6f96419950729f3671185b847352890f074f7557} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
580 | 580 | ca819180edb99ed25ceafb3e9584ac287e240b00 1337133713371337133713371337133713371337 0 (Thu Jan 01 00:22:18 1970 +0000) {'user': 'test'} |
|
581 | 581 | cda648ca50f50482b7055c0b0c4c117bba6733d9 3de5eca88c00aa039da7399a220f4a5221faa585 0 (*) {'user': 'test'} (glob) |
|
582 | 582 | cdbce2fbb16313928851e97e0d85413f3f7eb77f ca819180edb99ed25ceafb3e9584ac287e240b00 0 (Thu Jan 01 00:22:17 1970 +0000) {'user': 'test'} |
|
583 | 583 | |
|
584 | 584 | #if serve |
|
585 | 585 | |
|
586 | 586 | check hgweb does not explode |
|
587 | 587 | ==================================== |
|
588 | 588 | |
|
589 | 589 | $ hg unbundle $TESTDIR/bundles/hgweb+obs.hg |
|
590 | 590 | adding changesets |
|
591 | 591 | adding manifests |
|
592 | 592 | adding file changes |
|
593 | 593 | added 62 changesets with 63 changes to 9 files (+60 heads) |
|
594 | 594 | (run 'hg heads .' to see heads, 'hg merge' to merge) |
|
595 | 595 | $ for node in `hg log -r 'desc(babar_)' --template '{node}\n'`; |
|
596 | 596 | > do |
|
597 | 597 | > hg debugobsolete $node |
|
598 | 598 | > done |
|
599 | 599 | $ hg up tip |
|
600 | 600 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
601 | 601 | |
|
602 | 602 | $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log |
|
603 | 603 | $ cat hg.pid >> $DAEMON_PIDS |
|
604 | 604 | |
|
605 | 605 | check changelog view |
|
606 | 606 | |
|
607 | 607 | $ "$TESTDIR/get-with-headers.py" --headeronly localhost:$HGPORT 'shortlog/' |
|
608 | 608 | 200 Script output follows |
|
609 | 609 | |
|
610 | 610 | check graph view |
|
611 | 611 | |
|
612 | 612 | $ "$TESTDIR/get-with-headers.py" --headeronly localhost:$HGPORT 'graph' |
|
613 | 613 | 200 Script output follows |
|
614 | 614 | |
|
615 | 615 | check filelog view |
|
616 | 616 | |
|
617 | 617 | $ "$TESTDIR/get-with-headers.py" --headeronly localhost:$HGPORT 'log/'`hg id --debug --id`/'babar' |
|
618 | 618 | 200 Script output follows |
|
619 | 619 | |
|
620 | 620 | $ "$TESTDIR/get-with-headers.py" --headeronly localhost:$HGPORT 'rev/68' |
|
621 | 621 | 200 Script output follows |
|
622 | 622 | $ "$TESTDIR/get-with-headers.py" --headeronly localhost:$HGPORT 'rev/67' |
|
623 | 623 | 404 Not Found |
|
624 | 624 | [1] |
|
625 | 625 | |
|
626 | 626 | check that web.view config option: |
|
627 | 627 | |
|
628 | 628 | $ "$TESTDIR/killdaemons.py" hg.pid |
|
629 | 629 | $ cat >> .hg/hgrc << EOF |
|
630 | 630 | > [web] |
|
631 | 631 | > view=all |
|
632 | 632 | > EOF |
|
633 | 633 | $ wait |
|
634 | 634 | $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log |
|
635 | 635 | $ "$TESTDIR/get-with-headers.py" --headeronly localhost:$HGPORT 'rev/67' |
|
636 | 636 | 200 Script output follows |
|
637 | 637 | $ "$TESTDIR/killdaemons.py" hg.pid |
|
638 | 638 | |
|
639 | 639 | Checking _enable=False warning if obsolete marker exists |
|
640 | 640 | |
|
641 | 641 | $ echo '[extensions]' >> $HGRCPATH |
|
642 | 642 | $ echo "obs=!" >> $HGRCPATH |
|
643 | 643 | $ hg log -r tip |
|
644 | 644 | obsolete feature not enabled but 68 markers found! |
|
645 | 645 | 68:c15e9edfca13 (draft) [tip ] add celestine |
|
646 | 646 | |
|
647 | 647 | reenable for later test |
|
648 | 648 | |
|
649 | 649 | $ echo '[extensions]' >> $HGRCPATH |
|
650 | 650 | $ echo "obs=${TESTTMP}/obs.py" >> $HGRCPATH |
|
651 | 651 | |
|
652 | 652 | #endif |
|
653 | 653 | |
|
654 | 654 | Test incoming/outcoming with changesets obsoleted remotely, known locally |
|
655 | 655 | =============================================================================== |
|
656 | 656 | |
|
657 | 657 | This test issue 3805 |
|
658 | 658 | |
|
659 | 659 | $ hg init repo-issue3805 |
|
660 | 660 | $ cd repo-issue3805 |
|
661 | 661 | $ echo "foo" > foo |
|
662 | 662 | $ hg ci -Am "A" |
|
663 | 663 | adding foo |
|
664 | 664 | $ hg clone . ../other-issue3805 |
|
665 | 665 | updating to branch default |
|
666 | 666 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
667 | 667 | $ echo "bar" >> foo |
|
668 | 668 | $ hg ci --amend |
|
669 | 669 | $ cd ../other-issue3805 |
|
670 | 670 | $ hg log -G |
|
671 | 671 | @ 0:193e9254ce7e (draft) [tip ] A |
|
672 | 672 | |
|
673 | 673 | $ hg log -G -R ../repo-issue3805 |
|
674 | 674 | @ 2:3816541e5485 (draft) [tip ] A |
|
675 | 675 | |
|
676 | 676 | $ hg incoming |
|
677 | 677 | comparing with $TESTTMP/tmpe/repo-issue3805 (glob) |
|
678 | 678 | searching for changes |
|
679 | 679 | 2:3816541e5485 (draft) [tip ] A |
|
680 | 680 | $ hg incoming --bundle ../issue3805.hg |
|
681 | 681 | comparing with $TESTTMP/tmpe/repo-issue3805 (glob) |
|
682 | 682 | searching for changes |
|
683 | 683 | 2:3816541e5485 (draft) [tip ] A |
|
684 | 684 | $ hg outgoing |
|
685 | 685 | comparing with $TESTTMP/tmpe/repo-issue3805 (glob) |
|
686 | 686 | searching for changes |
|
687 | 687 | no changes found |
|
688 | 688 | [1] |
|
689 | 689 | |
|
690 | 690 | #if serve |
|
691 | 691 | |
|
692 | 692 | $ hg serve -R ../repo-issue3805 -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log |
|
693 | 693 | $ cat hg.pid >> $DAEMON_PIDS |
|
694 | 694 | |
|
695 | 695 | $ hg incoming http://localhost:$HGPORT |
|
696 | 696 | comparing with http://localhost:$HGPORT/ |
|
697 | 697 | searching for changes |
|
698 | 698 | 1:3816541e5485 (public) [tip ] A |
|
699 | 699 | $ hg outgoing http://localhost:$HGPORT |
|
700 | 700 | comparing with http://localhost:$HGPORT/ |
|
701 | 701 | searching for changes |
|
702 | 702 | no changes found |
|
703 | 703 | [1] |
|
704 | 704 | |
|
705 | 705 | $ "$TESTDIR/killdaemons.py" $DAEMON_PIDS |
|
706 | 706 | |
|
707 | 707 | #endif |
|
708 | 708 | |
|
709 | 709 | This test issue 3814 |
|
710 | 710 | |
|
711 | 711 | (nothing to push but locally hidden changeset) |
|
712 | 712 | |
|
713 | 713 | $ cd .. |
|
714 | 714 | $ hg init repo-issue3814 |
|
715 | 715 | $ cd repo-issue3805 |
|
716 | 716 | $ hg push -r 3816541e5485 ../repo-issue3814 |
|
717 | 717 | pushing to ../repo-issue3814 |
|
718 | 718 | searching for changes |
|
719 | 719 | adding changesets |
|
720 | 720 | adding manifests |
|
721 | 721 | adding file changes |
|
722 | 722 | added 1 changesets with 1 changes to 1 files |
|
723 | 723 | $ hg out ../repo-issue3814 |
|
724 | 724 | comparing with ../repo-issue3814 |
|
725 | 725 | searching for changes |
|
726 | 726 | no changes found |
|
727 | 727 | [1] |
|
728 | 728 | |
|
729 | 729 | Test that a local tag blocks a changeset from being hidden |
|
730 | 730 | |
|
731 | 731 | $ hg tag -l visible -r 0 --hidden |
|
732 | 732 | $ hg log -G |
|
733 | 733 | @ 2:3816541e5485 (draft) [tip ] A |
|
734 | 734 | |
|
735 | 735 | x 0:193e9254ce7e (draft) [visible ] A |
|
736 | 736 | |
|
737 | 737 | Test that removing a local tag does not cause some commands to fail |
|
738 | 738 | |
|
739 | 739 | $ hg tag -l -r tip tiptag |
|
740 | 740 | $ hg tags |
|
741 | 741 | tiptag 2:3816541e5485 |
|
742 | 742 | tip 2:3816541e5485 |
|
743 | 743 | visible 0:193e9254ce7e |
|
744 | 744 | $ hg --config extensions.strip= strip -r tip --no-backup |
|
745 | 745 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
746 | 746 | $ hg tags |
|
747 | 747 | visible 0:193e9254ce7e |
|
748 | 748 | tip 0:193e9254ce7e |
General Comments 0
You need to be logged in to leave comments.
Login now