diff options
author | Nathan Letwory <nathan@letworyinteractive.com> | 2008-10-20 02:01:46 +0400 |
---|---|---|
committer | Nathan Letwory <nathan@letworyinteractive.com> | 2008-10-20 02:01:46 +0400 |
commit | f1f27c0350bbff1aa7f444f75eab294dd6b78e16 (patch) | |
tree | 2abbd1bab0ed7b39be2fd458ac807cce3f570223 /source/blender/python | |
parent | 3544a4bd366c98bd5e514c7637ce0b1a369b6282 (diff) |
=== SCons ===
[#17867] Adds option to SCONS to generate Python API documentation
Added patch from Brandano with some small improvements (BF_DOCDIR, clean) by yours truly.
To use make sure you have epydoc installed. Enable with WITH_BF_BPYDOC=1.
Diffstat (limited to 'source/blender/python')
-rw-r--r-- | source/blender/python/api2_2x/doc/SConscript | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/source/blender/python/api2_2x/doc/SConscript b/source/blender/python/api2_2x/doc/SConscript new file mode 100644 index 00000000000..49d20894c58 --- /dev/null +++ b/source/blender/python/api2_2x/doc/SConscript @@ -0,0 +1,28 @@ +#!/usr/bin/python +Import ('env') + + +from optparse import OptionParser +try: + import epydoc +except ImportError: + print "No epydoc install detected, Python API Docs will not be generated " +if epydoc: + from epydoc.docbuilder import build_doc_index + from epydoc import cli + names = env.Glob("source/blender/python/api2_2x/doc/[A-Z]*.py") + docindex = build_doc_index(names) + optvalues = cli.OPTION_DEFAULTS + optvalues["verbose"] = 1 + optvalues["target"] = env["BF_DOCDIR"]+"/BPY_API/" + optvalues["url"] = "http://www.blender.org" + optvalues["top"] = "API_intro" + optvalues["name"] = "Blender" + optvalues["noprivate"] = 1 + optvalues["noframes"] = 1 + optvalues["names"] = names + optparser = OptionParser() + optparser.set_defaults(**optvalues) + (options, args) = optparser.parse_args() + cli.write_html(docindex, options) + |