/**
  * {@inheritdoc}
  */
 protected function initialize(InputInterface $input, OutputInterface $output)
 {
     $config = $input->getArgument(self::INPUT_KEY_CONFIG);
     $this->config->init($config);
     //@todo: interactively ask for config file
     $reset = $input->getOption(self::INPUT_KEY_RESET);
     if ($reset) {
         $output->writeln('Reset the current position of migration to start from the beginning');
         $this->progress->reset();
     }
     if ($output->getVerbosity() > 1) {
         $this->logManager->process($this->verbosityLevels[$output->getVerbosity()]);
     } else {
         $this->logManager->process();
     }
 }
Esempio n. 2
0
 /**
  * @return bool
  */
 protected function optionConfig()
 {
     $config = $this->getArg('config');
     if ($config) {
         $this->config->init($this->getArg('config'));
     }
     return $config ? true : false;
 }