rollback: clarifies the message about the reverted state (issue2628) stable
authorGilles Moris <gilles.moris@free.fr>
Thu, 10 Feb 2011 09:03:06 +0100
branchstable
changeset 884 fe775751eb93
parent 882 c3681742c0c7
child 885 57f7a3817083
child 887 64ae7e3ecd64
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) [ original upstream message ]
tests/test-keyword.t
--- a/tests/test-keyword.t	Sun Mar 06 14:19:57 2011 +0100
+++ b/tests/test-keyword.t	Thu Feb 10 09:03:06 2011 +0100
@@ -352,7 +352,8 @@
   +bar
 
   $ hg rollback
-  rolling back to revision 2 (undo commit)
+  repository tip rolled back to revision 2 (undo commit)
+  working directory now based on revision 2
 
 Record all chunks in file a
 
@@ -394,7 +395,8 @@
   xxx $
   bar
   $ hg --verbose rollback
-  rolling back to revision 2 (undo commit)
+  repository tip rolled back to revision 2 (undo commit)
+  working directory now based on revision 2
   overwriting a expanding keywords
   $ hg status a
   M a
@@ -411,7 +413,8 @@
   $ cat z
   $Id: z,v 45a5d3adce53 1970/01/01 00:00:00 test $
   $ hg --verbose rollback
-  rolling back to revision 2 (undo commit)
+  repository tip rolled back to revision 2 (undo commit)
+  working directory now based on revision 2
   overwriting z shrinking keywords
 
 Only z should be overwritten
@@ -437,7 +440,8 @@
   committed changeset 3:899491280810
   overwriting r expanding keywords
   $ hg --verbose rollback
-  rolling back to revision 2 (undo commit)
+  repository tip rolled back to revision 2 (undo commit)
+  working directory now based on revision 2
   overwriting r shrinking keywords
   $ hg forget r
   $ rm msg r
@@ -601,7 +605,8 @@
 Status after rollback:
 
   $ hg rollback
-  rolling back to revision 1 (undo commit)
+  repository tip rolled back to revision 1 (undo commit)
+  working directory now based on revision 1
   $ hg status
   A c
   $ hg update --clean
@@ -622,7 +627,8 @@
   $ rm x
 
   $ hg rollback
-  rolling back to revision 1 (undo commit)
+  repository tip rolled back to revision 1 (undo commit)
+  working directory now based on revision 1
   $ hg update --clean
   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ rm i symignored
@@ -735,7 +741,8 @@
 Rollback, revert, and check expansion
 
   $ hg rollback
-  rolling back to revision 2 (undo commit)
+  repository tip rolled back to revision 2 (undo commit)
+  working directory now based on revision 2
   $ hg status
   R a
   ? c
@@ -811,7 +818,8 @@
   ignore $Id$
 
   $ hg rollback
-  rolling back to revision 2 (undo commit)
+  repository tip rolled back to revision 2 (undo commit)
+  working directory now based on revision 2
   $ hg update --clean
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved