Hability to output `verbose` message in `GitException`
Hello, thanks for PR. Why you need this change? You can just use:
try {
// $git->open()
// $gitRepository->xyz()
} catch (CzProject\GitPhp\GitException $e) {
$e->getRunnerResult()->toText();
}
Hello @janpecha
Exactly the ideia is to avoid to call runner, and access directly toText message int default Exception::getMessage if verbose mode is enabled of course.
It seems useless for me. If I can call Exception::getMessage() I can call $e->getRunnerResult()->toText() too.
What about to add new method GitException::getVerboseMessage() - then you can call $e->getVerboseMessage()?
It seems useless for me. If I can call
Exception::getMessage()I can call$e->getRunnerResult()->toText()too.What about to add new method
GitException::getVerboseMessage()- then you can call$e->getVerboseMessage()?
You are right @janpecha ! Thanks
Nice! Can you fix static analysis & code style errors please? And change commit message to something like GitException: added method getVerboseMessage().