diff options
author | Martin v. Löwis <martin@v.loewis.de> | 2003-06-14 09:03:46 (GMT) |
---|---|---|
committer | Martin v. Löwis <martin@v.loewis.de> | 2003-06-14 09:03:46 (GMT) |
commit | b8c084e82c7bae771c0197b177f5c32c7e513c74 (patch) | |
tree | 1ac43899fcbb953a0bb88c2dcdc50bee959959bf /Lib/pydoc.py | |
parent | 17fb50790dfb662c05b073fdc44861ca0a735533 (diff) | |
download | cpython-b8c084e82c7bae771c0197b177f5c32c7e513c74.zip cpython-b8c084e82c7bae771c0197b177f5c32c7e513c74.tar.gz cpython-b8c084e82c7bae771c0197b177f5c32c7e513c74.tar.bz2 |
Support keyword and topics help in cli(). Fixes #715782.
Diffstat (limited to 'Lib/pydoc.py')
-rwxr-xr-x | Lib/pydoc.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Lib/pydoc.py b/Lib/pydoc.py index fe114fd..abafc0e 100755 --- a/Lib/pydoc.py +++ b/Lib/pydoc.py @@ -2116,7 +2116,7 @@ def cli(): else: writedoc(arg) else: - doc(arg) + help.help(arg) except ErrorDuringImport, value: print value @@ -2126,9 +2126,11 @@ def cli(): %s <name> ... Show text documentation on something. <name> may be the name of a - function, module, or package, or a dotted reference to a class or - function within a module or module in a package. If <name> contains - a '%s', it is used as the path to a Python source file to document. + Python keyword, topic, function, module, or package, or a dotted + reference to a class or function within a module or module in a + package. If <name> contains a '%s', it is used as the path to a + Python source file to document. If name is 'keywords', 'topics', + or 'modules', a listing of these things is displayed. %s -k <keyword> Search for a keyword in the synopsis lines of all available modules. |