Total Complexity | 2 |
Total Lines | 29 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
28 | class OnBranch implements Condition |
||
29 | { |
||
30 | /** |
||
31 | * Branch name to compare |
||
32 | * |
||
33 | * @var string |
||
34 | */ |
||
35 | private $name; |
||
36 | |||
37 | /** |
||
38 | * OnBranch constructor. |
||
39 | * |
||
40 | * @param string $name |
||
41 | */ |
||
42 | public function __construct(string $name) |
||
45 | } |
||
46 | |||
47 | /** |
||
48 | * Check is the current branch is equal to the configured one |
||
49 | * |
||
50 | * @param \CaptainHook\App\Console\IO $io |
||
51 | * @param \SebastianFeldmann\Git\Repository $repository |
||
52 | * @return bool |
||
53 | */ |
||
54 | public function isTrue(IO $io, Repository $repository): bool |
||
59 |