[PATCH 3 of 4] help: remove redundant parameter

Olav Reinert seroton10 at gmail.com
Tue May 22 15:11:42 CDT 2012


# HG changeset patch
# User Olav Reinert <seroton10 at gmail.com>
# Date 1337717321 -7200
# Node ID f7fadf491a24fef0eb225903428077b851fe0f4e
# Parent  d00bbe12035ac97272e69a5208d11ebdaa46e79d
help: remove redundant parameter

diff -r d00bbe12035a -r f7fadf491a24 mercurial/commands.py
--- a/mercurial/commands.py	Tue May 22 22:08:41 2012 +0200
+++ b/mercurial/commands.py	Tue May 22 22:08:41 2012 +0200
@@ -3089,7 +3089,7 @@
 
     textwidth = min(ui.termwidth(), 80) - 2
 
-    def addglobalopts(optlist, aliases):
+    def addglobalopts(optlist):
         if ui.quiet:
             return []
 
@@ -3104,11 +3104,9 @@
                         'or "hg -v" for details')
             elif name and not full:
                 msg = _('use "hg help %s" to show the full help text') % name
-            elif aliases:
+            else:
                 msg = _('use "hg -v help%s" to show builtin aliases and '
                         'global options') % (name and " " + name or "")
-            else:
-                msg = _('use "hg -v help %s" to show more info') % name
             optlist.append((msg, ()))
 
     def helpcmd(name):
@@ -3253,7 +3251,7 @@
                 ui.write(" %-*s   %s\n" % (topics_len, t, desc))
 
         optlist = []
-        addglobalopts(optlist, True)
+        addglobalopts(optlist)
         ui.write(help.opttext(optlist, textwidth, ui.verbose))
 
     def helptopic(name):


More information about the Mercurial-devel mailing list