1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76
|
The standard format used for documentation of packages and other
things in Tcllib is [term doctools].
Its supporting packages are a part of Tcllib, see the directories
[file modules/doctools] and [file modules/dtplite]. The latter is
an application package, with the actual application
[file apps/dtplite] a light wrapper around it.
[para] Tcllib developers gain access to these through the [cmd doc]
method of the [file sak.tcl] tool, another (internal) wrapper around
the [file modules/dtplite] application package.
[comment {===================================================================}]
[subsection {Generate documentation for a specific module}]
Invoke either
[example { ./sak.tcl doc html foo }]
or
[example { ./sak.tcl doc html modules/foo }]
to generate HTML for the documentation found in the module [file foo].
Instead of [const html] any other supported format can be used here,
of course.
[para] The generated formatted documentation will be placed into a
directory [file doc] in the current working directory.
[comment {===================================================================}]
[subsection {Generate documentation for all modules}]
Invoke the tool without a module name, i.e.
[example { ./sak.tcl doc html }]
to generate HTML for the documentation found in all modules.
Instead of [const html] any other supported format can be used here,
of course.
[para] The generated formatted documentation will be placed into a
directory [file doc] in the current working directory.
[comment {===================================================================}]
[subsection {Available output formats, help}]
Invoke the tool as
[example { ./sak.tcl help doc }]
to see the entire set of supported output formats which can be
generated.
[comment {===================================================================}]
[subsection {Validation without output}]
Note the special format [const validate].
[para] Using this value as the name of the format to generate forces
the tool to simply check that the documentation is syntactically
correct, without generating actual output.
[para] Invoke it as either
[example { ./sak.tcl doc validate (modules/)foo }]
or
[example { ./sak.tcl doc validate }]
to either check the packages of a specific module or check all of
them.
|