@@ -703,6 +703,13 @@ export async function commitFiles({
...
@@ -703,6 +703,13 @@ export async function commitFiles({
returncommit;
returncommit;
}catch (err)/* istanbul ignore next */{
}catch (err)/* istanbul ignore next */{
checkForPlatformFailure(err);
checkForPlatformFailure(err);
if (err.message.includes(`'refs/heads/renovate' exists`)){
consterror=newError(CONFIG_VALIDATION);
error.configFile='None';
error.validationError='An existing branch is blocking Renovate';
error.validationMessage=`Renovate needs to create the branch "${branchName}" but is blocked from doing so because of an existing branch called "renovate". Please remove it so that Renovate can proceed.`;
throwerror;
}
if (
if (
err.message.includes(
err.message.includes(
'refusing to allow a GitHub App to create or update workflow'
'refusing to allow a GitHub App to create or update workflow'