summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd Leonhardt <todd.leonhardt@gmail.com>2018-01-15 13:18:01 -0500
committerTodd Leonhardt <todd.leonhardt@gmail.com>2018-01-15 13:18:01 -0500
commitda0a44888312eefba3f6d8c07efd784875691129 (patch)
tree8d3cd58a162a187c84df1da8d05e4a1ff7f1cc30
parentb51d31bbec6960da1137762ac6217675cf368a40 (diff)
downloadcmd2-git-da0a44888312eefba3f6d8c07efd784875691129.tar.gz
Updated README.md due to @withargument_parser decorator now only passing a single argument to do_* methods
-rwxr-xr-xREADME.md6
1 files changed, 3 insertions, 3 deletions
diff --git a/README.md b/README.md
index 0144f4c3..2a3cb0f5 100755
--- a/README.md
+++ b/README.md
@@ -105,7 +105,7 @@ Instructions for implementing each feature follow.
argparser.add_argument('-s', '--shout', action='store_true', help='N00B EMULATION MODE')
argparser.add_argument('words', nargs='+', help='words to say')
@with_argument_parser(argparser)
- def do_speak(self, cmdline, args=None):
+ def do_speak(self, args):
"""Repeats what you tell me to."""
words = []
for word in args.words:
@@ -175,7 +175,7 @@ class CmdLineApp(Cmd):
argparser.add_argument('-r', '--repeat', type=int, help='output [n] times')
argparser.add_argument('words', nargs='+', help='words to say')
@with_argument_parser(argparser)
- def do_speak(self, cmdline, opts=None):
+ def do_speak(self, args):
"""Repeats what you tell me to."""
words = []
for word in args.words:
@@ -196,7 +196,7 @@ class CmdLineApp(Cmd):
argparser.add_argument('-r', '--repeat', type=int, help='how many times to repeat')
argparser.add_argument('words', nargs='+', help='words to say')
@with_argument_parser(argparser)
- def do_mumble(self, cmdline, args=None):
+ def do_mumble(self, args):
"""Mumbles what you tell me to."""
repetitions = args.repeat or 1
for i in range(min(repetitions, self.maxrepeats)):