diff --git a/dev-infra/pr/merge/index.ts b/dev-infra/pr/merge/index.ts index 4a6f5a5fd5..3f53b3d85e 100644 --- a/dev-infra/pr/merge/index.ts +++ b/dev-infra/pr/merge/index.ts @@ -33,6 +33,10 @@ import {MergeResult, MergeStatus, PullRequestMergeTask} from './task'; export async function mergePullRequest( prNumber: number, githubToken: string, projectRoot: string = getRepoBaseDir(), config?: MergeConfigWithRemote) { + // Set the environment variable to skip all git commit hooks triggered by husky. We are unable to + // rely on `---no-verify` as some hooks still run, notably the `prepare-commit-msg` hook. + process.env['HUSKY_SKIP_HOOKS'] = '1'; + const api = await createPullRequestMergeTask(githubToken, projectRoot, config); // Perform the merge. Force mode can be activated through a command line flag.