Test Failed
Pull Request — master (#354)
by Mihai
03:17
created

PhiveInstallCommand   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
c 1
b 0
f 0
dl 0
loc 14
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __toString() 0 3 1
A __construct() 0 4 1
1
<?php declare(strict_types=1);
2
3
namespace Zalas\Toolbox\Tool\Command;
4
5
use Zalas\Toolbox\Tool\Command;
6
7
final class PhiveInstallCommand implements Command
8
{
9
    private $alias;
10
    private $bin;
11
12
    public function __construct(string $alias, string $bin)
13
    {
14
        $this->alias = $alias;
15
        $this->bin = $bin;
16
    }
17
18
    public function __toString(): string
19
    {
20
        return \sprintf('phive install -g %s -t %s', $this->alias, $this->bin);
21
    }
22
}
23