summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/decorator_example.py (renamed from examples/argparse_example.py)9
-rw-r--r--examples/transcripts/exampleSession.txt2
2 files changed, 5 insertions, 6 deletions
diff --git a/examples/argparse_example.py b/examples/decorator_example.py
index 236e2af4..5b8b303b 100755
--- a/examples/argparse_example.py
+++ b/examples/decorator_example.py
@@ -1,14 +1,13 @@
#!/usr/bin/env python
# coding=utf-8
-"""A sample application for cmd2 showing how to use argparse to
+"""A sample application showing how to use cmd2's argparse decorators to
process command line arguments for your application.
Thanks to cmd2's built-in transcript testing capability, it also
-serves as a test suite for argparse_example.py when used with the
-exampleSession.txt transcript.
+serves as a test suite when used with the exampleSession.txt transcript.
-Running `python argparse_example.py -t exampleSession.txt` will run
-all the commands in the transcript against argparse_example.py,
+Running `python decorator_example.py -t exampleSession.txt` will run
+all the commands in the transcript against decorator_example.py,
verifying that the output produced matches the transcript.
"""
import argparse
diff --git a/examples/transcripts/exampleSession.txt b/examples/transcripts/exampleSession.txt
index 38fb0659..8fa7c9bb 100644
--- a/examples/transcripts/exampleSession.txt
+++ b/examples/transcripts/exampleSession.txt
@@ -1,4 +1,4 @@
-# Run this transcript with "python argparse_example.py -t exampleSession.txt"
+# Run this transcript with "python decorator_example.py -t exampleSession.txt"
# The regex for colors is because no color on Windows.
# The regex for editor will match whatever program you use.
# regexes on prompts just make the trailing space obvious