File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 1010import cmd2
1111from cmd2 import (
1212 COMMAND_NAME ,
13+ argparse_custom ,
1314)
1415
1516
@@ -55,7 +56,9 @@ def do_deploy(self, _):
5556 """Deploy command"""
5657 self .poutput ('Deploy' )
5758
58- start_parser = cmd2 .DEFAULT_ARGUMENT_PARSER (description = 'Start' , epilog = 'my_decorator runs even with argparse errors' )
59+ start_parser = argparse_custom .DEFAULT_ARGUMENT_PARSER (
60+ description = 'Start' , epilog = 'my_decorator runs even with argparse errors'
61+ )
5962 start_parser .add_argument ('when' , choices = START_TIMES , help = 'Specify when to start' )
6063
6164 @my_decorator
@@ -72,7 +75,7 @@ def do_redeploy(self, _):
7275 """Redeploy command"""
7376 self .poutput ('Redeploy' )
7477
75- restart_parser = cmd2 .DEFAULT_ARGUMENT_PARSER (
78+ restart_parser = argparse_custom .DEFAULT_ARGUMENT_PARSER (
7679 description = 'Restart' , epilog = 'my_decorator does not run when argparse errors'
7780 )
7881 restart_parser .add_argument ('when' , choices = START_TIMES , help = 'Specify when to restart' )
You can’t perform that action at this time.
0 commit comments