/** * Run process scoped to this repository by setting --git-dir and --work-tree. * * @param type $command Command to execute * @param array $args Additional arguments * * @return type Running process */ public function run($command, array $args = []) { $baseCommand = ['--git-dir', $this->dir . '/.git', '--work-tree', $this->dir]; $process = Git::getProcess(array_merge($baseCommand, [$command]), $args); return Git::runProcess($process); }