diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2011-12-03 13:29:22 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2011-12-03 13:29:22 +0100 |
commit | ca32f08966f1b51fcb19460f0996bb0c4048e6fe (patch) | |
tree | ec04cc15b867bc21eedca904cea9af0254531a11 /includes/installer/MysqlUpdater.php | |
parent | a22fbfc60f36f5f7ee10d5ae6fe347340c2ee67c (diff) |
Update to MediaWiki 1.18.0
* also update ArchLinux skin to chagnes in MonoBook
* Use only css to hide our menu bar when printing
Diffstat (limited to 'includes/installer/MysqlUpdater.php')
-rw-r--r-- | includes/installer/MysqlUpdater.php | 36 |
1 files changed, 29 insertions, 7 deletions
diff --git a/includes/installer/MysqlUpdater.php b/includes/installer/MysqlUpdater.php index 9bbda5db..761d2338 100644 --- a/includes/installer/MysqlUpdater.php +++ b/includes/installer/MysqlUpdater.php @@ -163,18 +163,25 @@ class MysqlUpdater extends DatabaseUpdater { // 1.17 array( 'addTable', 'iwlinks', 'patch-iwlinks.sql' ), array( 'addIndex', 'iwlinks', 'iwl_prefix_title_from', 'patch-rename-iwl_prefix.sql' ), - array( 'addField', 'updatelog', 'ul_value', 'patch-ul_value.sql' ), + array( 'addField', 'updatelog', 'ul_value', 'patch-ul_value.sql' ), array( 'addField', 'interwiki', 'iw_api', 'patch-iw_api_and_wikiid.sql' ), - array( 'dropIndex', 'iwlinks', 'iwl_prefix', 'patch-kill-iwl_prefix.sql' ), - array( 'dropIndex', 'iwlinks', 'iwl_prefix_from_title', 'patch-kill-iwl_pft.sql' ), - array( 'addField', 'categorylinks', 'cl_collation', 'patch-categorylinks-better-collation.sql' ), + array( 'dropIndex', 'iwlinks', 'iwl_prefix', 'patch-kill-iwl_prefix.sql' ), + array( 'dropIndex', 'iwlinks', 'iwl_prefix_from_title', 'patch-kill-iwl_pft.sql' ), + array( 'addField', 'categorylinks', 'cl_collation', 'patch-categorylinks-better-collation.sql' ), array( 'doClFieldsUpdate' ), array( 'doCollationUpdate' ), array( 'addTable', 'msg_resource', 'patch-msg_resource.sql' ), array( 'addTable', 'module_deps', 'patch-module_deps.sql' ), - array( 'dropIndex', 'archive', 'ar_page_revid', 'patch-archive_kill_ar_page_revid.sql' ), - array( 'addIndex', 'archive', 'ar_revid', 'patch-archive_ar_revid.sql' ), + array( 'dropIndex', 'archive', 'ar_page_revid', 'patch-archive_kill_ar_page_revid.sql' ), + array( 'addIndex', 'archive', 'ar_revid', 'patch-archive_ar_revid.sql' ), array( 'doLangLinksLengthUpdate' ), + + // 1.18 + array( 'doUserNewTalkTimestampNotNull' ), + array( 'addIndex', 'user', 'user_email', 'patch-user_email_index.sql' ), + array( 'modifyField', 'user_properties', 'up_property', 'patch-up_property.sql' ), + array( 'addTable', 'uploadstash', 'patch-uploadstash.sql' ), + array( 'addTable', 'user_former_groups', 'patch-user_former_groups.sql'), ); } @@ -246,6 +253,9 @@ class MysqlUpdater extends DatabaseUpdater { */ protected function doIndexUpdate() { $meta = $this->db->fieldInfo( 'recentchanges', 'rc_timestamp' ); + if ( $meta === false ) { + throw new MWException( 'Missing rc_timestamp field of recentchanges table. Should not happen.' ); + } if ( $meta->isMultipleKey() ) { $this->output( "...indexes seem up to 20031107 standards\n" ); return; @@ -649,7 +659,7 @@ class MysqlUpdater extends DatabaseUpdater { foreach ( $res as $row ) { $count = ( $count + 1 ) % 100; if ( $count == 0 ) { - wfWaitForSlaves( 10 ); + wfWaitForSlaves(); } $this->db->insert( 'templatelinks', array( @@ -829,4 +839,16 @@ class MysqlUpdater extends DatabaseUpdater { $this->output( "...ll_lang is up-to-date.\n" ); } } + + protected function doUserNewTalkTimestampNotNull() { + $info = $this->db->fieldInfo( 'user_newtalk', 'user_last_timestamp' ); + if ( $info->isNullable() ) { + $this->output( "...user_last_timestamp is already nullable.\n" ); + return; + } + + $this->output( "Making user_last_timestamp nullable... " ); + $this->applyPatch( 'patch-user-newtalk-timestamp-null.sql' ); + $this->output( "done.\n" ); + } } |