* @todo document
* @ingroup Maintenance
*
- * @author Ashar Voultoiz <hashar at free dot fr>
+ * @author Antoine Musso <hashar at free dot fr>
* @author Brion Vibber
* @author Alexandre Emsenhuber
* @version first release
/**
* Read a line from the shell
* @param $prompt String
+ * @return string
*/
function readaline( $prompt = '' ) {
print $prompt;
* @param $exclude String: Additionals path regex to exclude
* @param $exclude_patterns String: Additionals path regex to exclude
* (LocalSettings.php, AdminSettings.php, .svn and .git directories are always excluded)
+ * @return string
*/
function generateConfigFile( $doxygenTemplate, $outputDirectory, $stripFromPath, $currentVersion, $svnstat, $input, $exclude, $exclude_patterns ) {
+ global $wgDoxyGenerateMan;
+
$template = file_get_contents( $doxygenTemplate );
// Replace template placeholders by correct values.
'{{EXCLUDE}}' => $exclude,
'{{EXCLUDE_PATTERNS}}' => $exclude_patterns,
'{{HAVE_DOT}}' => `which dot` ? 'YES' : 'NO',
+ '{{GENERATE_MAN}}' => $wgDoxyGenerateMan ? 'YES' : 'NO',
);
$tmpCfg = str_replace( array_keys( $replacements ), array_values( $replacements ), $template );
$tmpFileName = tempnam( wfTempDir(), 'mwdocgen-' );
$doxyOutput = realpath( $argv[$i] );
}
break;
+ case '--generate-man':
+ $wgDoxyGenerateMan = true;
+ break;
case '--help':
print <<<END
Usage: php mwdocgen.php [<command>] [<options>]
Other options:
--output <dir> Set output directory (default $doxyOutput)
+ --generate-man Generates man page documentation
--help Show this help and exit.