Liip\RMT\Command\ReleaseCommand::interact PHP Method

interact() protected method

protected interact ( Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output )
$input Symfony\Component\Console\Input\InputInterface
$output Symfony\Component\Console\Output\OutputInterface
    protected function interact(InputInterface $input, OutputInterface $output)
    {
        parent::interact($input, $output);
        // Fill up questions
        if (Context::get('information-collector')->hasMissingInformation()) {
            $questions = Context::get('information-collector')->getInteractiveQuestions();
            $this->getOutput()->writeSmallTitle('Information collect (' . count($questions) . ' questions)');
            $this->getOutput()->indent();
            $count = 1;
            foreach ($questions as $name => $question) {
                $answer = $this->getOutput()->askQuestion($question, $count++, $this->input);
                Context::get('information-collector')->setValueFor($name, $answer);
                $this->getOutput()->writeEmptyLine();
            }
            $this->getOutput()->unIndent();
        }
    }