# HG changeset patch # User Martin von Zweigbergk # Date 1607639962 28800 # Node ID aa4dbc14f7354557933072c99967d43f6d9c3c22 # Parent 4a0730b7127e5222d33639a82ab0c93448724026 diff: deprecate -r option The new `--from`/`--to` options should be enough to support all the uses cases and are easier to understand, so there is no reason that I'm aware of to use `-r` anymore. Differential Revision: https://phab.mercurial-scm.org/D9564 diff -r 4a0730b7127e -r aa4dbc14f735 mercurial/commands.py --- a/mercurial/commands.py Thu Dec 10 12:06:55 2020 -0800 +++ b/mercurial/commands.py Thu Dec 10 14:39:22 2020 -0800 @@ -2455,7 +2455,7 @@ @command( b'diff', [ - (b'r', b'rev', [], _(b'revision'), _(b'REV')), + (b'r', b'rev', [], _(b'revision (DEPRECATED)'), _(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')), diff -r 4a0730b7127e -r aa4dbc14f735 relnotes/next --- a/relnotes/next Thu Dec 10 12:06:55 2020 -0800 +++ b/relnotes/next Thu Dec 10 14:39:22 2020 -0800 @@ -21,7 +21,8 @@ debugstrip`. The extension remains for compatibility. * `hg diff` now supports `--from ` and `--to ` arguments as - clearer alternatives to `-r `. + clearer alternatives to `-r `. `-r ` has been + deprecated. * The memory footprint per changeset during pull/unbundle operations has been further reduced. diff -r 4a0730b7127e -r aa4dbc14f735 tests/test-help.t --- a/tests/test-help.t Thu Dec 10 12:06:55 2020 -0800 +++ b/tests/test-help.t Thu Dec 10 14:39:22 2020 -0800 @@ -665,7 +665,6 @@ options ([+] can be repeated): - -r --rev REV [+] revision --from REV1 revision to diff from --to REV2 revision to diff to -c --change REV change made by revision