Yaml - Replace Spyc with Symfony Yaml Component.

This commit is contained in:
Andrés Montañez
2014-06-13 09:31:44 -03:00
parent d55637a120
commit e10dea147f
15 changed files with 1796 additions and 1030 deletions
+3 -2
View File
@@ -10,6 +10,7 @@
namespace Mage;
use Mage\Yaml\Yaml;
use Exception;
/**
@@ -99,7 +100,7 @@ class Config
protected function loadGeneral()
{
if (file_exists('.mage/config/general.yml')) {
$this->config['general'] = spyc_load_file('.mage/config/general.yml');
$this->config['general'] = Yaml::parse(file_get_contents('.mage/config/general.yml'));
}
}
@@ -113,7 +114,7 @@ class Config
{
$environment = $this->getEnvironment();
if (($environment != false) && file_exists('.mage/config/environment/' . $environment . '.yml')) {
$this->config['environment'] = spyc_load_file('.mage/config/environment/' . $environment . '.yml');
$this->config['environment'] = Yaml::parse(file_get_contents('.mage/config/environment/' . $environment . '.yml'));
// Create temporal directory for clone
if (isset($this->config['environment']['deployment']['source']) && is_array($this->config['environment']['deployment']['source'])) {