dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Minor fixes to ParsoidVirtualRESTService"
[lhc/web/wiklou.git]
/
maintenance
/
mcc.php
diff --git
a/maintenance/mcc.php
b/maintenance/mcc.php
index
6b8487f
..
784ba0e
100644
(file)
--- a/
maintenance/mcc.php
+++ b/
maintenance/mcc.php
@@
-22,11
+22,12
@@
* @ingroup Maintenance
*/
* @ingroup Maintenance
*/
-/** */
+$optionsWithArgs = [ 'cache' ];
+$optionsWithoutArgs = [
+ 'debug', 'help'
+];
require_once __DIR__ . '/commandLine.inc';
require_once __DIR__ . '/commandLine.inc';
-$options = getopt( '', array( 'debug', 'help', 'cache:' ) );
-
$debug = isset( $options['debug'] );
$help = isset( $options['help'] );
$cache = isset( $options['cache'] ) ? $options['cache'] : null;
$debug = isset( $options['debug'] );
$help = isset( $options['help'] );
$cache = isset( $options['cache'] ) ? $options['cache'] : null;
@@
-35,10
+36,10
@@
if ( $help ) {
mccShowUsage();
exit( 0 );
}
mccShowUsage();
exit( 0 );
}
-$mcc = new MemcachedClient(
array(
+$mcc = new MemcachedClient(
[
'persistent' => true,
'debug' => $debug,
'persistent' => true,
'debug' => $debug,
-
)
);
+
]
);
if ( $cache ) {
if ( !isset( $wgObjectCaches[$cache] ) ) {
if ( $cache ) {
if ( !isset( $wgObjectCaches[$cache] ) ) {
@@
-81,7
+82,7
@@
EOF;
function mccGetHelp( $command ) {
$output = '';
function mccGetHelp( $command ) {
$output = '';
- $commandList =
array(
+ $commandList =
[
'get' => 'grabs something',
'getsock' => 'lists sockets',
'set' => 'changes something',
'get' => 'grabs something',
'getsock' => 'lists sockets',
'set' => 'changes something',
@@
-92,7
+93,7
@@
function mccGetHelp( $command ) {
'exit' => 'exit mcc',
'quit' => 'exit mcc',
'help' => 'help about a command',
'exit' => 'exit mcc',
'quit' => 'exit mcc',
'help' => 'help about a command',
-
)
;
+
]
;
if ( !$command ) {
$command = 'fullhelp';
}
if ( !$command ) {
$command = 'fullhelp';
}