Code Duplication    Length = 4-8 lines in 3 locations

src/Kunstmaan/GeneratorBundle/Command/GenerateBundleCommand.php 3 locations

@@ 70-77 (lines=8) @@
67
    {
68
        $questionHelper = $this->getQuestionHelper();
69
70
        if ($input->isInteractive()) {
71
            $confirmationQuestion = new ConfirmationQuestion($questionHelper->getQuestion('Do you confirm generation', 'yes', '?'), true);
72
            if (!$questionHelper->ask($input, $output, $confirmationQuestion)) {
73
                $output->writeln('<error>Command aborted</error>');
74
75
                return 1;
76
            }
77
        }
78
79
        GeneratorUtils::ensureOptionsProvided($input, ['namespace', 'dir']);
80
@@ 217-220 (lines=4) @@
214
    protected function updateKernel(QuestionHelper $questionHelper, InputInterface $input, OutputInterface $output, KernelInterface $kernel, $namespace, $bundle)
215
    {
216
        $auto = true;
217
        if ($input->isInteractive()) {
218
            $confirmationQuestion = new ConfirmationQuestion($questionHelper->getQuestion('Confirm automatic update of your Kernel', 'yes', '?'), true);
219
            $auto = $questionHelper->ask($input, $output, $confirmationQuestion);
220
        }
221
222
        $output->write('Enabling the bundle inside the Kernel: ');
223
        $manip = new KernelManipulator($kernel);
@@ 251-254 (lines=4) @@
248
    protected function updateRouting(QuestionHelper $questionHelper, InputInterface $input, OutputInterface $output, $bundle, $format)
249
    {
250
        $auto = true;
251
        if ($input->isInteractive()) {
252
            $confirmationQuestion = new ConfirmationQuestion($questionHelper->getQuestion('Confirm automatic update of the Routing', 'yes', '?'), true);
253
            $auto = $questionHelper->ask($input, $output, $confirmationQuestion);
254
        }
255
256
        $output->write('Importing the bundle routing resource: ');
257
        $routing = new RoutingManipulator($this