浏览代码

changed name of the option to optimize-autoloader

Robert Boloc 11 年之前
父节点
当前提交
8a221854b1

+ 1 - 1
doc/04-schema.md

@@ -710,7 +710,7 @@ The following options are supported:
   interoperability issues with other autoloaders.
   interoperability issues with other autoloaders.
 * **autoloader-suffix:** Defaults to `null`. String to be used as a suffix for
 * **autoloader-suffix:** Defaults to `null`. String to be used as a suffix for
   the generated Composer autoloader. When null a random one will be generated.
   the generated Composer autoloader. When null a random one will be generated.
-* **autoloader-optimize-always** Defaults to `false`. Always optimize when dumping
+* **optimize-autoloader** Defaults to `false`. Always optimize when dumping
   the autoloader.
   the autoloader.
 * **github-domains:** Defaults to `["github.com"]`. A list of domains to use in
 * **github-domains:** Defaults to `["github.com"]`. A list of domains to use in
   github mode. This is used for GitHub Enterprise setups.
   github mode. This is used for GitHub Enterprise setups.

+ 1 - 1
res/composer-schema.json

@@ -180,7 +180,7 @@
                     "type": "string",
                     "type": "string",
                     "description": "Optional string to be used as a suffix for the generated Composer autoloader. When null a random one will be generated."
                     "description": "Optional string to be used as a suffix for the generated Composer autoloader. When null a random one will be generated."
                 },
                 },
-                "autoloader-optimize-always": {
+                "optimize-autoloader": {
                     "type": "boolean",
                     "type": "boolean",
                     "description": "Always optimize when dumping the autoloader"
                     "description": "Always optimize when dumping the autoloader"
                 },
                 },

+ 1 - 1
src/Composer/Command/ConfigCommand.php

@@ -283,7 +283,7 @@ EOT
                 }
                 }
             ),
             ),
             'autoloader-suffix' => array('is_string', function ($val) { return $val === 'null' ? null : $val; }),
             'autoloader-suffix' => array('is_string', function ($val) { return $val === 'null' ? null : $val; }),
-            'autoloader-optimize-always' => array($booleanValidator, $booleanNormalizer),
+            'optimize-autoloader' => array($booleanValidator, $booleanNormalizer),
             'prepend-autoloader' => array($booleanValidator, $booleanNormalizer),
             'prepend-autoloader' => array($booleanValidator, $booleanNormalizer),
         );
         );
         $multiConfigValues = array(
         $multiConfigValues = array(

+ 1 - 1
src/Composer/Command/DumpAutoloadCommand.php

@@ -51,7 +51,7 @@ EOT
         $package = $composer->getPackage();
         $package = $composer->getPackage();
         $config = $composer->getConfig();
         $config = $composer->getConfig();
 
 
-        $optimize = $input->getOption('optimize') || $config->get('autoloader-optimize-always');
+        $optimize = $input->getOption('optimize') || $config->get('optimize-autoloader');
 
 
         if ($optimize) {
         if ($optimize) {
             $output->writeln('<info>Generating optimized autoload files</info>');
             $output->writeln('<info>Generating optimized autoload files</info>');

+ 1 - 1
src/Composer/Config.php

@@ -36,7 +36,7 @@ class Config
         'cache-files-maxsize' => '300MiB',
         'cache-files-maxsize' => '300MiB',
         'discard-changes' => false,
         'discard-changes' => false,
         'autoloader-suffix' => null,
         'autoloader-suffix' => null,
-        'autoloader-optimize-always' => false,
+        'optimize-autoloader' => false,
         'prepend-autoloader' => true,
         'prepend-autoloader' => true,
         'github-domains' => array('github.com'),
         'github-domains' => array('github.com'),
     );
     );