GitCommandException   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
c 1
b 0
f 0
dl 0
loc 13
ccs 8
cts 8
cp 1
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 9 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Vasoft\VersionIncrement\Exceptions;
6
7
class GitCommandException extends ApplicationException
8
{
9
    protected int $applicationCode = 60;
10
11 1
    public function __construct(string $command, array $output, ?\Throwable $previous = null)
12
    {
13 1
        parent::__construct(
14 1
            sprintf(
15 1
                "Error executing Git command: git %s\n%s",
16 1
                $command,
17 1
                implode("\n", $output),
18 1
            ),
19 1
            $previous,
20 1
        );
21
    }
22
}
23