private function runCustomGit(array $arguments, GitRepository $git)
    {
        $process = new Process($this->prepareProcessArguments($arguments), $git->getRepositoryPath());
        $git->getConfig()->getLogger()->debug(
            \sprintf('[git-php] exec [%s] %s', $process->getWorkingDirectory(), $process->getCommandLine())
        );

        $process->run();
        $result = rtrim($process->getOutput(), "\r\n");

        if (!$process->isSuccessful()) {
            throw GitException::createFromProcess('Could not execute git command', $process);
        }

        return $result;
    }
private function runCustomGit(array $arguments, GitRepository $git)
    {
        $process = new Process($this->prepareProcessArguments($arguments), $git->getRepositoryPath());
        $git->getConfig()->getLogger()->debug(
            \sprintf('[git-php] exec [%s] %s', $process->getWorkingDirectory(), $process->getCommandLine())
        );

        $process->run();
        $result = rtrim($process->getOutput(), "\r\n");

        if (!$process->isSuccessful()) {
            throw GitException::createFromProcess('Could not execute git command', $process);
        }

        return $result;
    }
private function runCustomGit ( array $ arguments , GitRepository $ git ) { $ process = new Process ( $ this -> prepareProcessArguments ( $ arguments ) , $ git -> getRepositoryPath ( ) ) ; $ git -> getConfig ( ) -> getLogger ( ) -> debug ( \ sprintf ( '[git-php] exec [%s] %s' , $ process -> getWorkingDirectory ( ) , $ process -> getCommandLine ( ) ) ) ; $ process -> run ( ) ; $ result = rtrim ( $ process -> getOutput ( ) , "\r\n" ) ; if ( ! $ process -> isSuccessful ( ) ) { throw GitException :: createFromProcess ( 'Could not execute git command' , $ process ) ; } return $ result ; }
Run a custom git process.

@param array         $arguments A list of git arguments.
@param GitRepository $git       The git repository.

@return string

@throws GitException When the git execution failed.
@throws \ReflectionException Thrown if the class does not exist.
Run a custom git process .