LocalSettings generation tweaks:
authorMax Semenik <maxsem@users.mediawiki.org>
Tue, 8 Mar 2011 09:28:13 +0000 (09:28 +0000)
committerMax Semenik <maxsem@users.mediawiki.org>
Tue, 8 Mar 2011 09:28:13 +0000 (09:28 +0000)
* Mention extensions only if user chose some during installation
* Added a comment at the bottom suggesting where to put new settings

includes/installer/LocalSettingsGenerator.php

index 37ddd61..5439430 100644 (file)
@@ -111,7 +111,10 @@ class LocalSettingsGenerator {
                $localSettings = $this->getDefaultText();
 
                if( count( $this->extensions ) ) {
-                       $localSettings .= "\n# The following extensions were automatically enabled:\n";
+                       $localSettings .= "
+# Enabled Extensions. Most extensions are enabled by including the base extension file here
+# but check specific extension documentation for more details
+# The following extensions were automatically enabled:\n";
 
                        foreach( $this->extensions as $extName ) {
                                $encExtName = self::escapePhpString( $extName );
@@ -119,6 +122,9 @@ class LocalSettingsGenerator {
                        }
                }
 
+               $localSettings .= "\n\n# End of automatically generated settings.
+# Add more configuration options below.\n\n";
+
                return $localSettings;
        }
 
@@ -305,9 +311,6 @@ if ( !defined( 'MEDIAWIKI' ) ) {
 
 # Path to the GNU diff3 utility. Used for conflict resolution.
 \$wgDiff3 = \"{$this->values['wgDiff3']}\";
-
-# Enabled Extensions. Most extensions are enabled by including the base extension file here
-# but check specific extension documentation for more details
 ";
        }