dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d3978dc
)
justify help memcached console help
author
Antoine Musso
<hashar@users.mediawiki.org>
Sat, 13 Nov 2010 10:33:30 +0000
(10:33 +0000)
committer
Antoine Musso
<hashar@users.mediawiki.org>
Sat, 13 Nov 2010 10:33:30 +0000
(10:33 +0000)
maintenance/mcc.php
patch
|
blob
|
history
diff --git
a/maintenance/mcc.php
b/maintenance/mcc.php
index
f13c444
..
92f6863
100644
(file)
--- a/
maintenance/mcc.php
+++ b/
maintenance/mcc.php
@@
-31,8
+31,12
@@
function mccShowHelp( $command ) {
$command = 'fullhelp';
}
if ( $command === 'fullhelp' ) {
+ $max_cmd_len = 0;
+ foreach( array_keys( $commandList ) as $cmd ) {
+ $max_cmd_len = max( $max_cmd_len, strlen($cmd) );
+ }
foreach ( $commandList as $cmd => $desc ) {
- print
"$cmd: $desc\n"
;
+ print
f( "%-{$max_cmd_len}s: %s\n", $cmd, $desc )
;
}
} elseif ( isset( $commandList[$command] ) ) {
print "$command: $commandList[$command]\n";