From 2295414faea0421f621c52487ad36e24c7e54285 Mon Sep 17 00:00:00 2001 From: Brian Wolff Date: Sat, 7 Jul 2018 15:32:12 +0000 Subject: [PATCH] Only show config-install-success on command line installer where it makes sense In the web installer this isn't the last step and there is a different success message. Replace the existing config-install-success with a much more generic config-install-db-success message. Previously we were telling people to go to their wiki prior to them downloading LocalSettings.php which would obviously not work. Change-Id: I56e28157a1a4d55e4eeda5fdd536289960511938 --- includes/installer/Installer.php | 4 +--- includes/installer/i18n/en.json | 1 + includes/installer/i18n/qqq.json | 3 ++- maintenance/install.php | 5 +++++ 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/includes/installer/Installer.php b/includes/installer/Installer.php index 029f67d57a..1186485bd0 100644 --- a/includes/installer/Installer.php +++ b/includes/installer/Installer.php @@ -1607,9 +1607,7 @@ abstract class Installer { } if ( $status->isOk() ) { $this->showMessage( - 'config-install-success', - $this->getVar( 'wgServer' ), - $this->getVar( 'wgScriptPath' ) + 'config-install-db-success' ); $this->setVar( '_InstallDone', true ); } diff --git a/includes/installer/i18n/en.json b/includes/installer/i18n/en.json index 3202ca44dc..f6e756ddc5 100644 --- a/includes/installer/i18n/en.json +++ b/includes/installer/i18n/en.json @@ -301,6 +301,7 @@ "config-install-done": "Congratulations!\nYou have installed MediaWiki.\n\nThe installer has generated a LocalSettings.php file.\nIt contains all your configuration.\n\nYou will need to download it and put it in the base of your wiki installation (the same directory as index.php). The download should have started automatically.\n\nIf the download was not offered, or if you cancelled it, you can restart the download by clicking the link below:\n\n$3\n\nNote: If you do not do this now, this generated configuration file will not be available to you later if you exit the installation without downloading it.\n\nWhen that has been done, you can [$2 enter your wiki].", "config-install-done-path": "Congratulations!\nYou have installed MediaWiki.\n\nThe installer has generated a LocalSettings.php file.\nIt contains all your configuration.\n\nYou will need to download it and put it at $4. The download should have started automatically.\n\nIf the download was not offered, or if you cancelled it, you can restart the download by clicking the link below:\n\n$3\n\nNote: If you do not do this now, this generated configuration file will not be available to you later if you exit the installation without downloading it.\n\nWhen that has been done, you can [$2 enter your wiki].", "config-install-success": "MediaWiki has been successfully installed. You can now visit <$1$2> to view your wiki.\nIf you have questions, check out our frequently asked questions list:\n or use one of the\nsupport forums linked on that page.", + "config-install-db-success": "Database was successfully set up", "config-download-localsettings": "Download LocalSettings.php", "config-help": "help", "config-help-tooltip": "click to expand", diff --git a/includes/installer/i18n/qqq.json b/includes/installer/i18n/qqq.json index bf1976979c..7c86a5a0e0 100644 --- a/includes/installer/i18n/qqq.json +++ b/includes/installer/i18n/qqq.json @@ -322,7 +322,8 @@ "config-install-mainpage-failed": "Used as error message. Parameters:\n* $1 - detailed error message", "config-install-done": "Parameters:\n* $1 is the URL to LocalSettings download\n* $2 is a link to the wiki.\n* $3 is a download link with attached download icon. The config-download-localsettings message will be used as the link text.", "config-install-done-path": "Parameters:\n* $1 is the URL to LocalSettings download\n* $2 is a link to the wiki.\n* $3 is a download link with attached download icon. The config-download-localsettings message will be used as the link text.\n* $4 is the filesystem location of where the LocalSettings.php file should be saved to.", - "config-install-success": "Gives user information that installation was successful. Parameters:\n* $1 - server name\n* $2 - script path", + "config-install-db-success": "Shown after DB is set up. In web installer this is step prior to downloading LocalSettings.php", + "config-install-success": "Gives user information that installation was successful. Only shown in command line installer. Parameters:\n* $1 - server name\n* $2 - script path", "config-download-localsettings": "The link text used in the download link in config-install-done.", "config-help": "This is used in help boxes.\n{{Identical|Help}}", "config-help-tooltip": "Tooltip for the 'help' links ({{msg-mw|config-help}}), to make it clear they'll expand in place rather than open a new page", diff --git a/maintenance/install.php b/maintenance/install.php index 3395458d9f..1dd1909497 100644 --- a/maintenance/install.php +++ b/maintenance/install.php @@ -129,6 +129,11 @@ class CommandLineInstaller extends Maintenance { $installer->execute(); $installer->writeConfigurationFile( $this->getOption( 'confpath', $IP ) ); } + $installer->showMessage( + 'config-install-success', + $installer->getVar( 'wgServer' ), + $installer->getVar( 'wgScriptPath' ) + ); } private function setDbPassOption() { -- 2.20.1