cvs: phd / config.php package.xml

From: Date: Thu, 10 Jan 2008 17:53:21 +0000
Subject: cvs: phd / config.php package.xml
Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-1023@lists.php.net to get a copy of this message
bjori Thu Jan 10 17:53:21 2008 UTC Modified files: /phd package.xml config.php Log: Added option (-l/--list) to list the supported formats/themes (thanks Tony!) :) http://cvs.php.net/viewvc.cgi/phd/package.xml?r1=1.23&r2=1.24&diff_format=u Index: phd/package.xml diff -u phd/package.xml:1.23 phd/package.xml:1.24 --- phd/package.xml:1.23 Thu Jan 10 17:39:38 2008 +++ phd/package.xml Thu Jan 10 17:53:21 2008 @@ -27,6 +27,7 @@ - Removed support for phnotify - Fixed E_NOTICE on empty references - Added index chaching (Edward Z.) + - Added option (-l/--list) to list the supported formats/themes </notes> <contents> <dir baseinstalldir="phd" name="/"> http://cvs.php.net/viewvc.cgi/phd/config.php?r1=1.18&r2=1.19&diff_format=u Index: phd/config.php diff -u phd/config.php:1.18 phd/config.php:1.19 --- phd/config.php:1.18 Thu Jan 10 17:40:47 2008 +++ phd/config.php Thu Jan 10 17:53:21 2008 @@ -1,5 +1,5 @@ <?php -/* $Id: config.php,v 1.18 2008/01/10 17:40:47 bjori Exp $ */ +/* $Id: config.php,v 1.19 2008/01/10 17:53:21 bjori Exp $ */ function v($msg) { $args = func_get_args(); @@ -57,6 +57,7 @@ "docbook:" => "d:", // The Docbook XML file to render from (.manual.xml) "partial:" => "p:", // The ID to render (optionally ignoring its childrens) "verbose:" => "v", // Adjust the verbosity level + "list::" => "l::", // List supported themes/formats "version" => "V", // Print out version information "help" => "h", // Print out help ); @@ -133,6 +134,42 @@ break; /* }}} */ + /* {{{ Print out a list of formats/themes */ + case "l": + case "list": + /* FIXME: This list should be created dynamically */ + foreach((array)$v as $val) { + switch($val) { + case "f": + case "format": + case "formats": + echo "Supported formats:\n"; + echo "\txhtml\n"; + break; + + case "t": + case "theme": + case "themes": + echo "Supported themes:\n"; + echo "\tphpweb\n"; + echo "\tchunkedhtml\n"; + echo "\tbightml\n"; + break; + + case false: + echo "Supported formats:\n"; + echo "\txhtml\n"; + echo "Supported themes:\n"; + echo "\tphpweb\n"; + echo "\tchunkedhtml\n"; + echo "\tbightml\n"; + break; + } + } + exit(0); + break; + /* }}} */ + /* {{{ Partial rendering */ case "p": case "partial": @@ -225,6 +262,8 @@ --docbook <filename> The Docbook file to render from -p <id[=bool]> --partial <id[=bool]> The ID to render, optionally ignoring its children pages (default to true; render childrens) + -l <formats/themes> + --list <formats/themes> Print out the supported formats/themes (default: both) -V --version Print the PhD version information -h

« previous php.doc.cvs (#1023) next »