comparison tests/test-keyword.t @ 13446:1e497df514e2 stable

rollback: clarifies the message about the reverted state (issue2628) Previously, when rolling back a transaction, some users could be confused between the level to which the store is rolled back, and the new parents of the working directory. $ hg rollback rolling back to revision 4 (undo commit) With this change: $ hg rollback repository tip rolled back to tip revision 4 (undo commit) working directory now based on revision 2 and 1 So now the user can realize that the store has been rolled back to an older tip, but also that the working directory may not on the tip (here we are rolling back the merge of the heads 2 and 1)
author Gilles Moris <gilles.moris@free.fr>
date Thu, 10 Feb 2011 09:03:06 +0100
parents f715e6bd8091
children 1bb2a56a9d73
comparison
equal deleted inserted replaced
13445:61a898576888 13446:1e497df514e2
350 do not process $Id: 350 do not process $Id:
351 xxx $ 351 xxx $
352 +bar 352 +bar
353 353
354 $ hg rollback 354 $ hg rollback
355 rolling back to revision 2 (undo commit) 355 repository tip rolled back to revision 2 (undo commit)
356 working directory now based on revision 2
356 357
357 Record all chunks in file a 358 Record all chunks in file a
358 359
359 $ echo foo > msg 360 $ echo foo > msg
360 361
392 foo 393 foo
393 do not process $Id: 394 do not process $Id:
394 xxx $ 395 xxx $
395 bar 396 bar
396 $ hg --verbose rollback 397 $ hg --verbose rollback
397 rolling back to revision 2 (undo commit) 398 repository tip rolled back to revision 2 (undo commit)
399 working directory now based on revision 2
398 overwriting a expanding keywords 400 overwriting a expanding keywords
399 $ hg status a 401 $ hg status a
400 M a 402 M a
401 $ cat a 403 $ cat a
402 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ 404 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
409 $ hg add y 411 $ hg add y
410 $ hg commit -Am "rollback only" z 412 $ hg commit -Am "rollback only" z
411 $ cat z 413 $ cat z
412 $Id: z,v 45a5d3adce53 1970/01/01 00:00:00 test $ 414 $Id: z,v 45a5d3adce53 1970/01/01 00:00:00 test $
413 $ hg --verbose rollback 415 $ hg --verbose rollback
414 rolling back to revision 2 (undo commit) 416 repository tip rolled back to revision 2 (undo commit)
417 working directory now based on revision 2
415 overwriting z shrinking keywords 418 overwriting z shrinking keywords
416 419
417 Only z should be overwritten 420 Only z should be overwritten
418 421
419 $ hg status a y z 422 $ hg status a y z
435 examine changes to 'r'? [Ynsfdaq?] 438 examine changes to 'r'? [Ynsfdaq?]
436 r 439 r
437 committed changeset 3:899491280810 440 committed changeset 3:899491280810
438 overwriting r expanding keywords 441 overwriting r expanding keywords
439 $ hg --verbose rollback 442 $ hg --verbose rollback
440 rolling back to revision 2 (undo commit) 443 repository tip rolled back to revision 2 (undo commit)
444 working directory now based on revision 2
441 overwriting r shrinking keywords 445 overwriting r shrinking keywords
442 $ hg forget r 446 $ hg forget r
443 $ rm msg r 447 $ rm msg r
444 $ hg update -C 448 $ hg update -C
445 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 449 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
599 +xxx $ 603 +xxx $
600 604
601 Status after rollback: 605 Status after rollback:
602 606
603 $ hg rollback 607 $ hg rollback
604 rolling back to revision 1 (undo commit) 608 repository tip rolled back to revision 1 (undo commit)
609 working directory now based on revision 1
605 $ hg status 610 $ hg status
606 A c 611 A c
607 $ hg update --clean 612 $ hg update --clean
608 0 files updated, 0 files merged, 0 files removed, 0 files unresolved 613 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
609 614
620 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ 625 expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $
621 $ hg forget x 626 $ hg forget x
622 $ rm x 627 $ rm x
623 628
624 $ hg rollback 629 $ hg rollback
625 rolling back to revision 1 (undo commit) 630 repository tip rolled back to revision 1 (undo commit)
631 working directory now based on revision 1
626 $ hg update --clean 632 $ hg update --clean
627 0 files updated, 0 files merged, 0 files removed, 0 files unresolved 633 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
628 $ rm i symignored 634 $ rm i symignored
629 635
630 Custom keywordmaps as argument to kwdemo 636 Custom keywordmaps as argument to kwdemo
733 ? c 739 ? c
734 740
735 Rollback, revert, and check expansion 741 Rollback, revert, and check expansion
736 742
737 $ hg rollback 743 $ hg rollback
738 rolling back to revision 2 (undo commit) 744 repository tip rolled back to revision 2 (undo commit)
745 working directory now based on revision 2
739 $ hg status 746 $ hg status
740 R a 747 R a
741 ? c 748 ? c
742 $ hg revert --no-backup --rev tip a 749 $ hg revert --no-backup --rev tip a
743 $ cat a 750 $ cat a
809 xxx $ 816 xxx $
810 $Xinfo: User Name <user@example.com>: rejects? $ 817 $Xinfo: User Name <user@example.com>: rejects? $
811 ignore $Id$ 818 ignore $Id$
812 819
813 $ hg rollback 820 $ hg rollback
814 rolling back to revision 2 (undo commit) 821 repository tip rolled back to revision 2 (undo commit)
822 working directory now based on revision 2
815 $ hg update --clean 823 $ hg update --clean
816 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 824 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
817 825
818 kwexpand/kwshrink on selected files 826 kwexpand/kwshrink on selected files
819 827