summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Lib/cmd.py1
-rw-r--r--Lib/test/test_cmd.py8
2 files changed, 5 insertions, 4 deletions
diff --git a/Lib/cmd.py b/Lib/cmd.py
index ae7f12ef18..05ba7e3bc6 100644
--- a/Lib/cmd.py
+++ b/Lib/cmd.py
@@ -294,6 +294,7 @@ class Cmd:
return list(commands | topics)
def do_help(self, arg):
+ 'List available commands with "help" or detailed help with "help cmd".'
if arg:
# XXX check arg syntax
try:
diff --git a/Lib/test/test_cmd.py b/Lib/test/test_cmd.py
index 8bb4e63592..ed9258b1bf 100644
--- a/Lib/test/test_cmd.py
+++ b/Lib/test/test_cmd.py
@@ -84,11 +84,11 @@ class samplecmdclass(cmd.Cmd):
<BLANKLINE>
Documented commands (type help <topic>):
========================================
- add
+ add help
<BLANKLINE>
Undocumented commands:
======================
- exit help shell
+ exit shell
<BLANKLINE>
Test for the function print_topics():
@@ -125,11 +125,11 @@ class samplecmdclass(cmd.Cmd):
<BLANKLINE>
Documented commands (type help <topic>):
========================================
- add
+ add help
<BLANKLINE>
Undocumented commands:
======================
- exit help shell
+ exit shell
<BLANKLINE>
help text for add
Hello from postloop