Completed
Push — master ( 1e296c...dace5d )
by Faiz
02:40
created

ConfigViewCommand::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 5
ccs 0
cts 0
cp 0
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 2
1
<?php
2
3
namespace FaizShukri\Quran\Commands;
4
5
use FaizShukri\Quran\Supports\Config;
6
use Symfony\Component\Console\Command\Command;
7
use Symfony\Component\Console\Input\InputInterface;
8
use Symfony\Component\Console\Output\OutputInterface;
9
10
class ConfigViewCommand extends Command
11
{
12
    private $config;
13
14
    /**
15
     * @codeCoverageIgnore
16
     */
17
    public function __construct()
18
    {
19
        parent::__construct();
20
        $this->config = new Config();
21
    }
22
23
    /**
24
     * @codeCoverageIgnore
25
     */
26
    protected function configure()
27
    {
28
        $this
29
            ->setName('config:path')
30
            ->setDescription('View configuration path');
31
    }
32
33
    protected function execute(InputInterface $input, OutputInterface $output)
34
    {
35
        $output->writeln("Config file: <info>{$this->config->configFile}</info>");
36
        $output->writeln("Data directory: <info>{$this->config->dataDir}</info>");
37
38
        return 0;
39
    }
40
}
41