Package::configure()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 1
eloc 4
c 2
b 0
f 0
nc 1
nop 0
dl 0
loc 6
rs 10
1
<?php
2
3
namespace LCI\MODX\Orchestrator\Console\Command;
4
5
use LCI\MODX\Console\Command\BaseCommand;
6
use LCI\MODX\Orchestrator\Orchestrator;
7
use Symfony\Component\Console\Input\InputInterface;
8
use Symfony\Component\Console\Output\OutputInterface;
9
10
class Package extends BaseCommand
11
{
12
    public $loadMODX = true;
13
14
    protected function configure()
15
    {
16
        $this
17
            ->setName('orchestrator:install')
18
            ->setAliases(['orch:install'])
19
            ->setDescription('Install/Update orchestrator');
20
    }
21
22
    /**
23
     * Runs the command.
24
     *
25
     * @param InputInterface $input
26
     * @param OutputInterface $output
27
     * @return int|null|void
28
     */
29
    protected function execute(InputInterface $input, OutputInterface $output)
30
    {
31
        Orchestrator::install();
32
33
        $output->writeln('### Orchestrator has been installed/updated ###');
34
    }
35
}
36