diff options
author | Robin Gareus <robin@gareus.org> | 2016-04-06 18:23:25 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-04-06 18:23:25 +0200 |
commit | 5e2c9f8ef8dd97f95a6da56ea1d6fea7bd89b611 (patch) | |
tree | 4b6966e3f33d2b2d151e1b6bd45d919120ef7a76 /tools/fmt-luadoc.php | |
parent | 563b792b57a9fcefb1ff217d7216add83dff4433 (diff) |
lua-doc: generate ardour-manual (template) directly
Diffstat (limited to 'tools/fmt-luadoc.php')
-rwxr-xr-x | tools/fmt-luadoc.php | 40 |
1 files changed, 35 insertions, 5 deletions
diff --git a/tools/fmt-luadoc.php b/tools/fmt-luadoc.php index 712c8b0887..2656b7e330 100755 --- a/tools/fmt-luadoc.php +++ b/tools/fmt-luadoc.php @@ -16,6 +16,13 @@ # php tools/fmt-luadoc.php > /tmp/luadoc.html # +$options = getopt("m"); +if (isset ($options['m'])) { + $HTMLOUTPUT = false; ## set to false to output ardour-manual +} else { + $HTMLOUTPUT = true; ## set to false to output ardour-manual +} + ################################################################################ ################################################################################ @@ -642,6 +649,8 @@ function format_class_members ($ns, $cl, &$dups) { ################################################################################ # Start Output +if ($HTMLOUTPUT) { + ?><!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <head> @@ -705,7 +714,26 @@ div.luafooter { text-align:center; font-size:80%; color: #888; margin: 2em </p> </div> -<!-- #### SNIP #### !--> +<!-- #### SNIP #### !--> + +<?php + +} else { + +?> +--- +layout: default +style: luadoc +title: Class Reference +--- + +<p class="warning"> +This documention is far from complete may be inaccurate and subject to change. +</p> + +<?php +} +?> <div id="luaref"> @@ -923,8 +951,10 @@ fwrite (STDERR, "Found $dox_found annotations. missing: $dox_miss\n"); ?> </div> <div class="luafooter">Ardour <?=$ardourversion?> - <?=date('r')?></div> +<?php -<!-- #### SNIP #### !--> - -</body> -</html> +if ($HTMLOUTPUT) { + echo '<!-- #### SNIP #### !-->'.NL; + echo '</body>'.NL; + echo '</html>'.NL; +} |