Show More
@@ -380,11 +380,7 b' def unshelvecleanup(ui, repo, name, opts' | |||||
380 | def finishmerge(ui, repo, ms, stripnodes, name, opts): |
|
380 | def finishmerge(ui, repo, ms, stripnodes, name, opts): | |
381 | # Reset the working dir so it's no longer in a merge state. |
|
381 | # Reset the working dir so it's no longer in a merge state. | |
382 | dirstate = repo.dirstate |
|
382 | dirstate = repo.dirstate | |
383 | for f in ms: |
|
383 | dirstate.setparents(dirstate._pl[0]) | |
384 | if dirstate[f] == 'm': |
|
|||
385 | dirstate.normallookup(f) |
|
|||
386 | dirstate._pl = (dirstate._pl[0], nullid) |
|
|||
387 | dirstate._dirty = dirstate._dirtypl = True |
|
|||
388 | shelvedstate.clear(repo) |
|
384 | shelvedstate.clear(repo) | |
389 |
|
385 | |||
390 | def unshelvecontinue(ui, repo, state, opts): |
|
386 | def unshelvecontinue(ui, repo, state, opts): |
@@ -328,7 +328,6 b' ensure the repo is as we hope' | |||||
328 | 3:2e69b451d1ea |
|
328 | 3:2e69b451d1ea | |
329 |
|
329 | |||
330 | $ hg status -C |
|
330 | $ hg status -C | |
331 | M a/a |
|
|||
332 | M b.rename/b |
|
331 | M b.rename/b | |
333 | b/b |
|
332 | b/b | |
334 | M c.copy |
|
333 | M c.copy | |
@@ -341,8 +340,6 b' there should be no shelves left' | |||||
341 |
|
340 | |||
342 | $ hg shelve -l |
|
341 | $ hg shelve -l | |
343 |
|
342 | |||
344 | $ hg commit -m whee a/a |
|
|||
345 |
|
||||
346 | #if execbit |
|
343 | #if execbit | |
347 |
|
344 | |||
348 | ensure that metadata-only changes are shelved |
|
345 | ensure that metadata-only changes are shelved | |
@@ -390,10 +387,9 b' if we resolve a conflict while unshelvin' | |||||
390 | merging a/a |
|
387 | merging a/a | |
391 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
388 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
392 | $ hg parents -q |
|
389 | $ hg parents -q | |
393 | 5:01ba9745dc5a |
|
390 | 4:33f7f61e6c5e | |
394 | $ hg shelve -l |
|
391 | $ hg shelve -l | |
395 | $ hg status |
|
392 | $ hg status | |
396 | M a/a |
|
|||
397 | A foo/foo |
|
393 | A foo/foo | |
398 | $ cat a/a |
|
394 | $ cat a/a | |
399 | a |
|
395 | a | |
@@ -423,12 +419,12 b' test bookmarks' | |||||
423 |
|
419 | |||
424 | $ hg bookmark test |
|
420 | $ hg bookmark test | |
425 | $ hg bookmark |
|
421 | $ hg bookmark | |
426 |
* test |
|
422 | * test 4:33f7f61e6c5e | |
427 | $ hg shelve |
|
423 | $ hg shelve | |
428 | shelved as test |
|
424 | shelved as test | |
429 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
425 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
430 | $ hg bookmark |
|
426 | $ hg bookmark | |
431 |
* test |
|
427 | * test 4:33f7f61e6c5e | |
432 | $ hg unshelve |
|
428 | $ hg unshelve | |
433 | unshelving change 'test' |
|
429 | unshelving change 'test' | |
434 | adding changesets |
|
430 | adding changesets | |
@@ -437,7 +433,7 b' test bookmarks' | |||||
437 | added 1 changesets with 1 changes to 7 files |
|
433 | added 1 changesets with 1 changes to 7 files | |
438 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
434 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
439 | $ hg bookmark |
|
435 | $ hg bookmark | |
440 |
* test |
|
436 | * test 4:33f7f61e6c5e | |
441 |
|
437 | |||
442 | shelve should still work even if mq is disabled |
|
438 | shelve should still work even if mq is disabled | |
443 |
|
439 | |||
@@ -453,3 +449,36 b' shelve should still work even if mq is d' | |||||
453 | adding file changes |
|
449 | adding file changes | |
454 | added 1 changesets with 1 changes to 7 files |
|
450 | added 1 changesets with 1 changes to 7 files | |
455 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
451 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
452 | ||||
|
453 | shelve should leave dirstate clean (issue 4055) | |||
|
454 | ||||
|
455 | $ cd .. | |||
|
456 | $ hg init shelverebase | |||
|
457 | $ cd shelverebase | |||
|
458 | $ printf 'x\ny\n' > x | |||
|
459 | $ echo z > z | |||
|
460 | $ hg commit -Aqm xy | |||
|
461 | $ echo z >> x | |||
|
462 | $ hg commit -Aqm z | |||
|
463 | $ hg up 0 | |||
|
464 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |||
|
465 | $ printf 'a\nx\ny\nz\n' > x | |||
|
466 | $ hg commit -Aqm xyz | |||
|
467 | $ echo c >> z | |||
|
468 | $ hg shelve | |||
|
469 | shelved as default | |||
|
470 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |||
|
471 | $ hg rebase -d 1 --config extensions.rebase= | |||
|
472 | merging x | |||
|
473 | saved backup bundle to $TESTTMP/shelverebase/.hg/strip-backup/323bfa07f744-backup.hg (glob) | |||
|
474 | $ hg unshelve | |||
|
475 | unshelving change 'default' | |||
|
476 | adding changesets | |||
|
477 | adding manifests | |||
|
478 | adding file changes | |||
|
479 | added 2 changesets with 2 changes to 2 files (+1 heads) | |||
|
480 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |||
|
481 | $ hg status | |||
|
482 | M z | |||
|
483 | ||||
|
484 | $ cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now