Merge remote-tracking branch 'stanlemon/configure-autoloader-suffix'
commit
d4b7548cd9
|
@ -176,6 +176,10 @@
|
|||
"type": ["string", "boolean"],
|
||||
"description": "The default style of handling dirty updates, defaults to false and can be any of true, false or \"stash\"."
|
||||
},
|
||||
"autoloader-suffix": {
|
||||
"type": "string",
|
||||
"description": "Optional string to be used as a suffix to the autoloader generator. When null a random one will be generated."
|
||||
},
|
||||
"prepend-autoloader": {
|
||||
"type": "boolean",
|
||||
"description": "If false, the composer autoloader will not be prepended to existing autoloaders, defaults to true."
|
||||
|
|
|
@ -169,7 +169,7 @@ EOF;
|
|||
$classmapFile .= ");\n";
|
||||
|
||||
if (!$suffix) {
|
||||
$suffix = md5(uniqid('', true));
|
||||
$suffix = $config->get('autoloader-suffix') ?: md5(uniqid('', true));
|
||||
}
|
||||
|
||||
file_put_contents($targetDir.'/autoload_namespaces.php', $namespacesFile);
|
||||
|
|
|
@ -35,6 +35,7 @@ class Config
|
|||
'cache-files-ttl' => null, // fallback to cache-ttl
|
||||
'cache-files-maxsize' => '300MiB',
|
||||
'discard-changes' => false,
|
||||
'autoload-suffix' => null,
|
||||
'prepend-autoloader' => true,
|
||||
'github-domains' => array('github.com'),
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue