Krinkle has uploaded a new change for review. https://gerrit.wikimedia.org/r/60833
Change subject: mwdocgen.php: Implement --version option. ...................................................................... mwdocgen.php: Implement --version option. So that the job that runs it can pass along what it should display (e.g. branch, tag, hash etc. whatever is appropiate for the context of that run). Change-Id: I1d5b6266e49a71672b0a53069e6ea6bb4658c3d2 --- M maintenance/mwdocgen.php 1 file changed, 11 insertions(+), 5 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/33/60833/1 diff --git a/maintenance/mwdocgen.php b/maintenance/mwdocgen.php index 0d9f3ab..3c35335 100644 --- a/maintenance/mwdocgen.php +++ b/maintenance/mwdocgen.php @@ -60,6 +60,8 @@ /** where Phpdoc should output documentation */ $doxyOutput = $mwPath . 'docs' . DIRECTORY_SEPARATOR ; +$doxyVersion = 'master'; + /** MediaWiki subpaths */ $mwPathI = $mwPath . 'includes/'; $mwPathL = $mwPath . 'languages/'; @@ -159,6 +161,12 @@ $doxyOutput = realpath( $argv[$i] ); } break; + case '--version': + $i++; + if ( isset( $argv[$i] ) ) { + $doxyVersion = $argv[$i]; + } + break; case '--generate-man': $wgDoxyGenerateMan = true; break; @@ -178,8 +186,9 @@ If no command is given, you will be prompted. Other options: - --output <dir> Set output directory (default $doxyOutput) + --output <dir> Set output directory (default: $doxyOutput) --generate-man Generates man page documentation + --version Project version to display in the outut (default: $doxyVersion) --help Show this help and exit. @@ -228,14 +237,11 @@ $exclude_patterns = 'extensions'; } -// @todo FIXME to work on git -$version = 'master'; - // Generate path exclusions $excludedPaths = $mwPath . join( " $mwPath", $mwExcludePaths ); print "EXCLUDE: $excludedPaths\n\n"; -$generatedConf = generateConfigFile( $doxygenTemplate, $doxyOutput, $mwPath, $version, $input, $excludedPaths, $exclude_patterns ); +$generatedConf = generateConfigFile( $doxygenTemplate, $doxyOutput, $mwPath, $doxyVersion, $input, $excludedPaths, $exclude_patterns ); $command = $doxygenBin . ' ' . $generatedConf; echo <<<TEXT -- To view, visit https://gerrit.wikimedia.org/r/60833 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I1d5b6266e49a71672b0a53069e6ea6bb4658c3d2 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: REL1_19 Gerrit-Owner: Krinkle <krinklem...@gmail.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits