Conditions | 2 |
Paths | 2 |
Total Lines | 13 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 6 |
Changes | 0 |
1 | <?php |
||
43 | private function getPhpDbgBinLocation(): string |
||
44 | { |
||
45 | $checkInPath = new Process('phpdbg --version'); |
||
46 | $checkInPath->run(); |
||
47 | if ($checkInPath->getExitCode() === 0) { |
||
48 | return 'phpdbg'; |
||
49 | } |
||
50 | |||
51 | $locator = new Process('command -v phpdbg'); |
||
52 | $locator->run(); |
||
53 | |||
54 | return (string)preg_replace('/\s/', '', $locator->getOutput()); |
||
55 | } |
||
56 | } |
||
57 |