| Total Complexity | 2 |
| Total Lines | 35 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 25 | class RepositoryAware extends ConfigAware |
||
| 26 | { |
||
| 27 | /** |
||
| 28 | * Runtime resolver to check for PHAR or lib execution |
||
| 29 | * |
||
| 30 | * @var \CaptainHook\App\Console\Runtime\Resolver |
||
| 31 | */ |
||
| 32 | protected $resolver; |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Configure method to setup the git-directory command option |
||
| 36 | * |
||
| 37 | * @return void |
||
| 38 | */ |
||
| 39 | protected function configure(): void |
||
| 40 | { |
||
| 41 | parent::configure(); |
||
| 42 | |||
| 43 | $this->addOption( |
||
| 44 | 'git-directory', |
||
| 45 | 'g', |
||
| 46 | InputOption::VALUE_OPTIONAL, |
||
| 47 | 'Path to your .git directory' |
||
| 48 | ); |
||
| 49 | } |
||
| 50 | |||
| 51 | /** |
||
| 52 | * Create a new git repository representation |
||
| 53 | * |
||
| 54 | * @param string $path |
||
| 55 | * @return \SebastianFeldmann\Git\Repository |
||
| 56 | */ |
||
| 57 | protected function createRepository(string $path): Repository |
||
| 60 | } |
||
| 61 | } |
||
| 62 |