[Updated] D9563: diff: update synopsis to use --from/--to instead of -r

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Fri Dec 11 05:40:02 UTC 2020


Closed by commit rHG4a0730b7127e: diff: update synopsis to use --from/--to instead of -r (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D9563?vs=24179&id=24182

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D9563/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D9563

AFFECTED FILES
  mercurial/commands.py
  tests/test-help.t

CHANGE DETAILS

diff --git a/tests/test-help.t b/tests/test-help.t
--- a/tests/test-help.t
+++ b/tests/test-help.t
@@ -629,7 +629,7 @@
   (some details hidden, use --verbose to show complete help)
 
   $ hg help diff
-  hg diff [OPTION]... ([-c REV] | [-r REV1 [-r REV2]]) [FILE]...
+  hg diff [OPTION]... ([-c REV] | [--from REV1] [--to REV2]) [FILE]...
   
   diff repository (or selected files)
   
@@ -666,8 +666,8 @@
   options ([+] can be repeated):
   
    -r --rev REV [+]         revision
-      --from REV            revision to diff from
-      --to REV              revision to diff to
+      --from REV1           revision to diff from
+      --to REV2             revision to diff to
    -c --change REV          change made by revision
    -a --text                treat all files as text
    -g --git                 use git extended diff format
diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -2456,15 +2456,15 @@
     b'diff',
     [
         (b'r', b'rev', [], _(b'revision'), _(b'REV')),
-        (b'', b'from', b'', _(b'revision to diff from'), _(b'REV')),
-        (b'', b'to', b'', _(b'revision to diff to'), _(b'REV')),
+        (b'', b'from', b'', _(b'revision to diff from'), _(b'REV1')),
+        (b'', b'to', b'', _(b'revision to diff to'), _(b'REV2')),
         (b'c', b'change', b'', _(b'change made by revision'), _(b'REV')),
     ]
     + diffopts
     + diffopts2
     + walkopts
     + subrepoopts,
-    _(b'[OPTION]... ([-c REV] | [-r REV1 [-r REV2]]) [FILE]...'),
+    _(b'[OPTION]... ([-c REV] | [--from REV1] [--to REV2]) [FILE]...'),
     helpcategory=command.CATEGORY_FILE_CONTENTS,
     helpbasic=True,
     inferrepo=True,



To: martinvonz, #hg-reviewers, mharbison72
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20201211/d93fe8fc/attachment-0002.html>


More information about the Mercurial-patches mailing list