public function isGitCommandAvailable($command = 'git')
    {
        exec('where ' . $command . ' 2>&1', $output, $returnValue);
        if ((new OsHelper())->isWindows() === false) {
            exec('which ' . $command . ' 2>&1', $output, $returnValue);
        }

        return $returnValue === 0;
    }
public function isGitCommandAvailable($command = 'git')
    {
        exec('where ' . $command . ' 2>&1', $output, $returnValue);
        if ((new OsHelper())->isWindows() === false) {
            exec('which ' . $command . ' 2>&1', $output, $returnValue);
        }

        return $returnValue === 0;
    }
public function isGitCommandAvailable ( $ command = 'git' ) { exec ( 'where ' . $ command . ' 2>&1' , $ output , $ returnValue ) ; if ( ( new OsHelper ( ) ) -> isWindows ( ) === false ) { exec ( 'which ' . $ command . ' 2>&1' , $ output , $ returnValue ) ; } return $ returnValue === 0 ; }
Is the Git command available?

@paramk string $command The command to check availabilty of. Defaults to git.

@return boolean
Is the Git command available?