File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -672,11 +672,12 @@ def cmdLineParser():
672672 parser .add_option_group (miscellaneous )
673673
674674 # Dirty hack for making a short option -hh
675- _ = parser .get_option ("--hh" )
676- _ ._short_opts = ["-hh" ]
677- _ ._long_opts = []
675+ option = parser .get_option ("--hh" )
676+ option ._short_opts = ["-hh" ]
677+ option ._long_opts = []
678678
679679 args = []
680+ advancedHelp = True
680681
681682 for arg in sys .argv :
682683 args .append (getUnicode (arg , system = True ))
@@ -686,6 +687,7 @@ def cmdLineParser():
686687 if sys .argv [i ] == '-hh' :
687688 sys .argv [i ] = '-h'
688689 elif sys .argv [i ] == '-h' :
690+ advancedHelp = False
689691 for group in parser .option_groups [:]:
690692 found = False
691693 for option in group .option_list :
@@ -699,7 +701,7 @@ def cmdLineParser():
699701 try :
700702 (args , _ ) = parser .parse_args (args )
701703 except SystemExit :
702- if '-h' in sys .argv :
704+ if '-h' in sys .argv and not advancedHelp :
703705 print "\n [!] to see full list of options run with '-hh'"
704706 raise
705707
You can’t perform that action at this time.
0 commit comments