Reference

pythondoc(1)

documentation generator for Python

NAME

pythondoc - documentation generator for Python

SYNOPSIS

pythondoc [-a] [-D] [-d dir] [-f format] [-h] [-i] [-l] [-o option_file] [-s dir] [-v] [key=value ...] files ...

DESCRIPTION

This manual page documents briefly the pythondoc command. This page was put together from the output of pythondoc -h for the Debian GNU/Linux distribution because the original program does not have a manual page.

pythondoc scans one or several python modules for documentation strings. From the documentation strings, manual pages are generated in any of FrameMaker MIF, MML, HTML and ASCII formats.

Note that you can give multiple format options at once. It is a lot faster, since the the source files are only parsed/imported and traversed once.

The key=value options are used to send arguments to formatters. These definitions can be put in the environment as well, where 'key' is an environment variable. The 'key' can either be '<module>_<keyname>', or just '<keyname>'. Options can also be read from option files. Option files are read from the directory /etc/pythondoc and your home directory (named pythondoc.opts), or by giving a filename with the -o option.

OPTIONS

The programs follow the usual GNU command line syntax, with long options starting with two dashes (`-'). A summary of options are included below.

-h, --help

Print help text.

-a, --all

Generate documentation for all modules in sys.path.

-D, --nodoc

Don't generate document pages.

-d dir, --directory dir

Save generated files in the dir directory.

-f format, --format format

Generate files using the formatter format

-i, --index

Generate index pages.

-l, --load

Load previously saved doctrees.

-o optionfile, --options optionfile

Load options from given file.

-s dir, --savedir dir

Save/read doctrees from given directory.

-v, --verbose

Verbose mode

key=value

Pass formatter options.

FORMATTER OPTIONS

The key=value options are used to send arguments to formatters. These definitions can be put in the environment as well.

all -- main: Traverse sys.path and document everything

(type: bool, default: 0)

options -- main: Pythondoc option file

(type: file path, default: )

document -- main: Generate document pages

(type: bool, default: 1)

directory -- main: Directory to store output

(type: directory path, default: .)

savedir -- main: Save doctrees

(type: directory path, default: )

head -- main: Generate head page

(type: bool, default: 0)

index -- main: Generate index pages

(type: bool, default: 0)

load -- main: Load previously saved doctrees

(type: bool, default: 0)

frame -- HTML4: Generate pages using frames

(type: bool, default: 0)

footer_file -- HTML4: HTML footer code file

(type: file path, default: /usr/lib/python1.5/site-packages/pythondoc/formatters/HTML4ValidateFooter.html)

header_file -- HTML4: HTML header file

(type: file path, default: /usr/lib/python1.5/site-packages/pythondoc/formatters/HTML4StdHeader.html)

stylesheet -- HTML4: CSS stylesheet URL

(type: URL, default: pythondoc.css)

foobar -- HTML4: Test enum

(type: Enumeration, default: Foo, valid values: ('Foo', 'bar', 'help'))

FORMATTERS

Currently the following formatters are supported:

XML
HTML4

AUTHOR

This manual page was written by Gregor Hoffleit <[email protected]>, for the Debian GNU/Linux system (but may be used by others).