Add ability to show the time taken by update.php

Bug: 28278

Change-Id: I42cd0da35a2ed20748374afbe1a02773cd941136
This commit is contained in:
mayankmadan 2013-11-03 20:17:02 +05:30
parent 63b41a21b9
commit fae8daa658

View file

@ -132,6 +132,8 @@ class UpdateMediaWiki extends Maintenance {
wfCountDown( 5 );
}
$time1 = new MWTimestamp();
$shared = $this->hasOption( 'doshared' );
$updates = array( 'core', 'extensions' );
@ -164,8 +166,10 @@ class UpdateMediaWiki extends Maintenance {
if ( !$this->hasOption( 'nopurge' ) ) {
$updater->purgeCache();
}
$time2 = new MWTimestamp();
$this->output( "\nDone.\n" );
$this->output( "\nThe job took ". $time2->diff( $time1 )->format( "%i:%S" ). "\n" );
}
function afterFinalSetup() {