Exemplo n.º 1
0
 /**
  * {@inheritdoc}
  */
 protected function initialize(InputInterface $input, OutputInterface $output)
 {
     parent::initialize($input, $output);
     // see http://qiita.com/ngyuki/items/d8db4ab6a954c59ed79d
     if ($output->getVerbosity() == $output::VERBOSITY_NORMAL && $input->getOption('verbose')) {
         $output->setVerbosity($output::VERBOSITY_VERBOSE);
     }
     $configPath = $input->getOption('config');
     $dryRun = $input->getOption('dry-run');
     $loader = new ConfigLoader();
     $fn = $loader->resolve($configPath);
     $config = $loader->load($fn);
     $config->dryRun = $dryRun;
     $logger = new Logger($output);
     $this->manager = new Manager($config, $logger);
 }
Exemplo n.º 2
0
 public function config()
 {
     $loader = new ConfigLoader();
     return $loader->load($this->configFile());
 }