Add missing namespace part.
Add missing use statements.
Set the git process working directory.
Use working directory and error output in exception message.
Use a protected run method to prevent strict compatibility warnings.