[PATCH 2 of 2 STABLE] doc: unify help text for "--edit" option

FUJIWARA Katsunori foozy at lares.dti.ne.jp
Tue Jul 29 10:19:23 CDT 2014


# HG changeset patch
# User FUJIWARA Katsunori <foozy at lares.dti.ne.jp>
# Date 1406646892 -32400
#      Wed Jul 30 00:14:52 2014 +0900
# Branch stable
# Node ID bfb2a78cd0f650d4a0cd42c23e353408127971d5
# Parent  eb34290835f26386a6a2194b9db0a03b99825682
doc: unify help text for "--edit" option

This patch changes help text for "--edit" option of commands below:

  - fetch
  - qnew
  - qrefresh
  - qfold
  - commit
  - tag

This unification reduces translation cost, too.

This patch chooses not "further edit commit message already specified"
(of "hg commit") but "invoke editor on commit messages" as unified
help text for "--edit" option, because the latter is much older than
the former.

diff --git a/hgext/fetch.py b/hgext/fetch.py
--- a/hgext/fetch.py
+++ b/hgext/fetch.py
@@ -19,7 +19,7 @@
 @command('fetch',
     [('r', 'rev', [],
      _('a specific revision you would like to pull'), _('REV')),
-    ('e', 'edit', None, _('edit commit message')),
+    ('e', 'edit', None, _('invoke editor on commit messages')),
     ('', 'force-editor', None, _('edit commit message (DEPRECATED)')),
     ('', 'switch-parent', None, _('switch parents when merging')),
     ] + commands.commitopts + commands.commitopts2 + commands.remoteopts,
diff --git a/hgext/mq.py b/hgext/mq.py
--- a/hgext/mq.py
+++ b/hgext/mq.py
@@ -2407,7 +2407,7 @@
         opts['date'] = "%d %d" % util.makedate()
 
 @command("^qnew",
-         [('e', 'edit', None, _('edit commit message')),
+         [('e', 'edit', None, _('invoke editor on commit messages')),
           ('f', 'force', None, _('import uncommitted changes (DEPRECATED)')),
           ('g', 'git', None, _('use git extended diff format')),
           ('U', 'currentuser', None, _('add "From: <current user>" to patch')),
@@ -2453,7 +2453,7 @@
     return 0
 
 @command("^qrefresh",
-         [('e', 'edit', None, _('edit commit message')),
+         [('e', 'edit', None, _('invoke editor on commit messages')),
           ('g', 'git', None, _('use git extended diff format')),
           ('s', 'short', None,
            _('refresh only files already in the patch and specified files')),
@@ -2523,7 +2523,7 @@
     return 0
 
 @command('qfold',
-         [('e', 'edit', None, _('edit patch header')),
+         [('e', 'edit', None, _('invoke editor on commit messages')),
           ('k', 'keep', None, _('keep folded patch files')),
          ] + commands.commitopts,
          _('hg qfold [-e] [-k] [-m TEXT] [-l FILE] PATCH...'))
diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -1339,8 +1339,7 @@
      _('mark a branch as closed, hiding it from the branch list')),
     ('', 'amend', None, _('amend the parent of the working dir')),
     ('s', 'secret', None, _('use the secret phase for committing')),
-    ('e', 'edit', None,
-     _('further edit commit message already specified')),
+    ('e', 'edit', None, _('invoke editor on commit messages')),
     ] + walkopts + commitopts + commitopts2 + subrepoopts,
     _('[OPTION]... [FILE]...'),
     inferrepo=True)
@@ -5695,7 +5694,7 @@
     ('r', 'rev', '', _('revision to tag'), _('REV')),
     ('', 'remove', None, _('remove a tag')),
     # -l/--local is already there, commitopts cannot be used
-    ('e', 'edit', None, _('edit commit message')),
+    ('e', 'edit', None, _('invoke editor on commit messages')),
     ('m', 'message', '', _('use text as commit message'), _('TEXT')),
     ] + commitopts2,
     _('[-f] [-l] [-m TEXT] [-d DATE] [-u USER] [-r REV] NAME...'))
diff --git a/tests/test-mq-qrefresh-interactive.t b/tests/test-mq-qrefresh-interactive.t
--- a/tests/test-mq-qrefresh-interactive.t
+++ b/tests/test-mq-qrefresh-interactive.t
@@ -31,7 +31,7 @@
   
   options:
   
-   -e --edit                edit commit message
+   -e --edit                invoke editor on commit messages
    -g --git                 use git extended diff format
    -s --short               refresh only files already in the patch and
                             specified files
@@ -75,7 +75,7 @@
   
   options:
   
-   -e --edit                edit commit message
+   -e --edit                invoke editor on commit messages
    -g --git                 use git extended diff format
    -s --short               refresh only files already in the patch and
                             specified files
diff --git a/tests/test-qrecord.t b/tests/test-qrecord.t
--- a/tests/test-qrecord.t
+++ b/tests/test-qrecord.t
@@ -62,7 +62,7 @@
                             list
       --amend               amend the parent of the working dir
    -s --secret              use the secret phase for committing
-   -e --edit                further edit commit message already specified
+   -e --edit                invoke editor on commit messages
    -I --include PATTERN [+] include names matching the given patterns
    -X --exclude PATTERN [+] exclude names matching the given patterns
    -m --message TEXT        use text as commit message
@@ -135,7 +135,7 @@
   
   options:
   
-   -e --edit                edit commit message
+   -e --edit                invoke editor on commit messages
    -g --git                 use git extended diff format
    -U --currentuser         add "From: <current user>" to patch
    -u --user USER           add "From: <USER>" to patch


More information about the Mercurial-devel mailing list