[Commits] r1437 - website
commits at geoext.org
commits at geoext.org
Thu Oct 15 10:02:59 CEST 2009
Author: tschaub
Date: 2009-10-15 10:02:59 +0200 (Thu, 15 Oct 2009)
New Revision: 1437
Modified:
website/jst.cfg
website/pavement.py
Log:
Adding paver task to concatenate comment blocks from examples and a jst config for parsing them.
Modified: website/jst.cfg
===================================================================
--- website/jst.cfg 2009-10-15 08:01:55 UTC (rev 1436)
+++ website/jst.cfg 2009-10-15 08:02:59 UTC (rev 1437)
@@ -3,3 +3,7 @@
template = src/trunk/docsrc/lib/template.jst
output = src/trunk/docsrc/lib
+[examples]
+root = src/trunk/geoext/examples/tmp
+template = src/trunk/docsrc/examples.jst
+output = src/trunk/docsrc/
Modified: website/pavement.py
===================================================================
--- website/pavement.py 2009-10-15 08:01:55 UTC (rev 1436)
+++ website/pavement.py 2009-10-15 08:02:59 UTC (rev 1437)
@@ -136,6 +136,18 @@
@task
+def parse_examples():
+ exdir = path("src/trunk/geoext/examples")
+ js = [p for p in exdir.listdir() if p.endswith(".js")]
+ odir = path("src/trunk/geoext/examples/tmp")
+ odir.mkdir()
+ out = odir / "examples.js"
+ h = out.open("w")
+ h.write("".join([f.open().read() for f in js]))
+ h.close()
+
+ at task
+ at needs(['pavement.parse_examples'])
def parse_docs():
from jstools.jst import DocParser
if not path('src/trunk').exists(): # add flag?
@@ -145,7 +157,6 @@
parser = DocParser.from_fn("jst.cfg")
parser.run()
-
@task
@needs(['pavement.parse_docs',
'paver.doctools.html'])
More information about the Commits
mailing list