feat: log git error message when authentication verification fails

This commit is contained in:
pvdlg
2018-05-04 12:19:24 -07:00
committed by Gregor Martynus
parent d1c3ad0b57
commit cd9f2bdd44
3 changed files with 11 additions and 4 deletions
+4 -1
View File
@@ -56,7 +56,10 @@ async function run(options, plugins) {
return false;
}
if (!await verifyAuth(options.repositoryUrl, options.branch)) {
try {
await verifyAuth(options.repositoryUrl, options.branch);
} catch (err) {
logger.error(`The command "${err.cmd}" failed with the error message %s.`, err.stderr);
throw getError('EGITNOPERMISSION', {options});
}