mirror of
https://github.com/composer/composer
synced 2025-05-10 17:12:51 +00:00
Fixes #4302 allow COMPOSER env with config statements (overrides --file)
This commit is contained in:
parent
c6cc6dd607
commit
9392adef79
1 changed files with 1 additions and 1 deletions
|
@ -139,7 +139,7 @@ EOT
|
|||
// passed in a file to use
|
||||
$configFile = $input->getOption('global')
|
||||
? ($this->config->get('home') . '/config.json')
|
||||
: $input->getOption('file');
|
||||
: (trim(getenv('COMPOSER')) ? trim(getenv('COMPOSER')) : $input->getOption('file'));
|
||||
|
||||
// create global composer.json if this was invoked using `composer global config`
|
||||
if ($configFile === 'composer.json' && !file_exists($configFile) && realpath(getcwd()) === realpath($this->config->get('home'))) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue