Skip to content

Commit

Permalink
Prevents setup command from using project directory if we are in a phar.
Browse files Browse the repository at this point in the history
  • Loading branch information
typhonius committed Mar 29, 2020
1 parent d9d8280 commit 065ab27
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/Commands/SetupCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@ class SetupCommand extends Tasks
*/
public function setup(Config $config)
{
$configFiles = [
'global' => $config->get('config.global'),
'project' => $config->get('config.project'),
];
$configFiles = ['global' => $config->get('config.global')];

// Do not include project configuration if this is running in a Phar.
if (!\Phar::running()) {
$configFiles['project'] = $config->get('config.project');
}

foreach ($configFiles as $type => $location) {
$this->say(sprintf('Checking %s configuration at %s', $type, $location));
Expand Down

0 comments on commit 065ab27

Please sign in to comment.