+<?
# This file is copied to the install directory so that
# later update scripts will be able to use it to determine
# what they need to update. The version number here must
#
$wgSoftwareRevision = 1001;
-
+?>
copyfile( "./math", "texvc_tex", "{$IP}/math", 0775 );
}
+copyfile( ".", "Version.php", $IP );
+
#
# Make and initialize database
#
print "Adding indexes...\n";
dbsource( $rconn, "./maintenance/indexes.sql" );
-copyfile( ".", "Version.php", $IP );
-
print "Done.\nBrowse \"{$wgServer}{$wgScript}\" to test,\n" .
"or \"run WikiSuite -b -o\" in test suite.\n";
exit();
}
}
+function readconsole() {
+ $fp = fopen( "php://stdin", "r" );
+ $resp = trim( fgets( $fp ) );
+ fclose( $fp );
+ return $resp;
+}
+
function do_revision_updates() {
global $wgSoftwareRevision;
function update_passwords() {
$fname = "Update scripte: update_passwords()";
- print "Updating passwords...\n";
+ print "\nIt appears that you need to update the user passwords in your\n" .
+ "database. If you have already done this (if you've run this update\n" .
+ "script once before, for example), doing so again will make all your\n" .
+ "user accounts inaccessible, so be sure you only do this once.\n" .
+ "Update user passwords? (yes/no) ";
+
+ $resp = readconsole();
+ if ( ! ( "Y" == $resp{0} || "y" == $resp{0} ) ) { return; }
$sql = "SELECT user_id,user_password FROM user";
$source = wfQuery( $sql, fname );