Completed
Push — master ( 79d213...eeff33 )
by Kamil
23:15
created

SynchronizeCommand::configure()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 1 Features 1
Metric Value
c 2
b 1
f 1
dl 0
loc 7
rs 9.4285
cc 1
eloc 4
nc 1
nop 0
1
<?php
2
3
/*
4
 * This file is part of the Sylius package.
5
 *
6
 * (c) Paweł Jędrzejewski
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Sylius\Bundle\ThemeBundle\Command;
13
14
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
15
use Symfony\Component\Console\Input\InputInterface;
16
use Symfony\Component\Console\Output\OutputInterface;
17
18
/**
19
 * @author Kamil Kokot <[email protected]>
20
 */
21
final class SynchronizeCommand extends ContainerAwareCommand
22
{
23
    /**
24
     * {@inheritdoc}
25
     */
26
    protected function configure()
27
    {
28
        $this
29
            ->setName('sylius:theme:synchronize')
30
            ->setDescription('Synchronize themes.')
31
        ;
32
    }
33
34
    /**
35
     * {@inheritdoc}
36
     */
37
    protected function execute(InputInterface $input, OutputInterface $output)
38
    {
39
        $output->write('Synchronizing themes... ');
40
41
        $this->getContainer()->get('sylius.theme.synchronizer')->synchronize();
42
43
        $output->writeln('Success!');
44
    }
45
}
46