Skip to content

Commit

Permalink
[console] Update loadExtendConfiguration feature. (#140)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmolivas committed Jan 23, 2017
1 parent 7488a97 commit ecec2d4
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions src/Utils/ConfigurationManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ public function appendCommandAliases()
}
}

public function loadExtendLibraries()
public function loadExtendConfiguration()
{
$directory = $this->getHomeDirectory() . '/.console/extend/';
if (!is_dir($directory)) {
Expand All @@ -296,14 +296,11 @@ public function loadExtendLibraries()
return null;
}
include_once $autoloadFile;

$extendFile = $directory . 'extend.yml';
if (!is_file($extendFile)) {
return null;
$extendFile = $directory . 'extend.console.config.yml';
if (is_file($extendFile)) {
$builder = new YamlFileConfigurationBuilder([$extendFile]);
$this->configuration->import($builder->build());
}
$builder = new YamlFileConfigurationBuilder([$extendFile]);

$this->configuration->import($builder->build());
}

/**
Expand Down Expand Up @@ -336,4 +333,5 @@ public function getSites()

return $this->sites;
}

}

0 comments on commit ecec2d4

Please sign in to comment.