Interim commit - adding support for zipping docs.
authorSalim Fadhley <sal@stodge.org>
Mon, 9 Jan 2012 15:15:04 +0000 (15:15 +0000)
committerSalim Fadhley <sal@stodge.org>
Mon, 9 Jan 2012 15:15:04 +0000 (15:15 +0000)
doc/build.properties [new file with mode: 0644]
doc/build.xml
doc/epydoc.cfg
doc/run_epydoc.py

diff --git a/doc/build.properties b/doc/build.properties
new file mode 100644 (file)
index 0000000..2cb145e
--- /dev/null
@@ -0,0 +1 @@
+docs.zipfile.filename=docs_html.zip
\ No newline at end of file
index 57e4896..c4073f7 100644 (file)
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>\r
 <project name="calyon_egg" default="all">\r
        <property file="build.properties"/>     \r
-       <target name="all" depends="clean,doc" />\r
        \r
+       <target name="all" depends="clean, doc, doc_zip" />\r
        <target name="clean" depends="doc_clean" />\r
        \r
        <target name="doc">\r
@@ -13,6 +13,7 @@
                                    <arg value="--name"/>\r
                                <arg value="JenkinsAPI"/>\r
                                    <arg value="--config=epydoc.cfg"/>\r
+                                       <arg value="--debug"/>\r
                </exec>\r
        </target>\r
        \r
                <delete failonerror="false">\r
                        <fileset dir="doc"/>\r
                </delete>\r
+               <delete failonerror="false">\r
+                       <file dir="${docs.zipfile.filename}"/>\r
+               </delete>\r
+       </target>\r
+       \r
+       <target name="doc_zip">\r
+               <zip destfile="${docs.zipfile.filename}" basedir="html/" />\r
        </target>\r
        \r
        \r
index e69de29..3c67ef5 100644 (file)
@@ -0,0 +1,19 @@
+[epydoc] # Epydoc section marker (required by ConfigParser)\r
+\r
+# Information about the project.\r
+name: JenkinsAPI\r
+url: https://github.com/salimfadhley/jenkinsapi\r
+\r
+# The list of modules to document.  Modules can be named using\r
+# dotted names, module filenames, or package directory names.\r
+# This option may be repeated.\r
+modules: jenkinsapi\r
+\r
+# Write html output to the directory "apidocs"\r
+output: html\r
+target: doc/html/\r
+\r
+# Include all automatically generated graphs.  These graphs are\r
+# generated using Graphviz dot.\r
+#graph: all\r
+#dotpath: /usr/local/bin/dot
\ No newline at end of file
index 96e2f63..aeb8556 100644 (file)
@@ -1,3 +1,5 @@
+import os, sys\r
+\r
 try:\r
     from epydoc.cli import cli\r
 except ImportError:\r
@@ -5,4 +7,9 @@ except ImportError:
     require("epydoc>=3.0.1")\r
     from epydoc.cli import cli\r
     \r
+DOC_DIR, _ = os.path.split( os.path.abspath( __file__ ) )\r
+PROJECT_DIR, _ = os.path.split( DOC_DIR )\r
+\r
+sys.path.insert( 0, PROJECT_DIR )\r
+    \r
 cli()
\ No newline at end of file