changeset 751:a5474648a9d2

gdown/gup: add next/previous alias Up and down refer to the customary order in log output rather than concepts; as such, it may be confusing to the user. I for one found them suprising -- they just didn't fit with my mental model. Previous and next, however, imply a clear parent/child relationship. We attroduce the new name as aliases for now.
author Dan Villiom Podlaski Christiansen <dan@cabo.dk>
date Fri, 15 Nov 2013 21:33:54 -0500
parents ddbea2fdee5e
children bfdfdf731f8a
files README hgext/evolve.py tests/test-uncommit.t
diffstat 3 files changed, 6 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/README	Tue Oct 22 11:51:01 2013 +0200
+++ b/README	Fri Nov 15 21:33:54 2013 -0500
@@ -51,6 +51,7 @@
 - parents command: add "working directory parent is obsolete" message
 - evolve command: allow updating to the successor if the parent is
   obsolete
+- gdown and gup commands: add next and previous alias, respectively
 
 3.1.0 -- 2013-02-11
 
--- a/hgext/evolve.py	Tue Oct 22 11:51:01 2013 +0200
+++ b/hgext/evolve.py	Fri Nov 15 21:33:54 2013 -0500
@@ -1238,10 +1238,10 @@
 
 shorttemplate = '[{rev}] {desc|firstline}\n'
 
-@command('^gdown',
+@command('^gdown|previous',
          [],
          '')
-def cmdgdown(ui, repo):
+def cmdprevious(ui, repo):
     """update to parent and display summary lines"""
     wkctx = repo[None]
     wparents = wkctx.parents()
@@ -1261,10 +1261,10 @@
         ui.warn(_('multiple parents, explicitly update to one\n'))
         return 1
 
-@command('^gup',
+@command('^gup|next',
          [],
          '')
-def cmdup(ui, repo):
+def cmdnext(ui, repo):
     """update to child and display summary lines"""
     wkctx = repo[None]
     wparents = wkctx.parents()
--- a/tests/test-uncommit.t	Tue Oct 22 11:51:01 2013 +0200
+++ b/tests/test-uncommit.t	Fri Nov 15 21:33:54 2013 -0500
@@ -328,7 +328,7 @@
   $ hg ci -m touncommit
   $ echo unrelated > unrelated
   $ hg ci -Am addunrelated unrelated
-  $ hg gdown
+  $ hg previous
   0 files updated, 0 files merged, 1 files removed, 0 files unresolved
   [8] touncommit
   $ hg uncommit aa