From a2e29b02cb9f1e33b0aec5e580a4e8151af4773c Mon Sep 17 00:00:00 2001 From: Josh-Cena Date: Thu, 11 Nov 2021 09:21:31 +0800 Subject: [PATCH] More tip about failure --- packages/docusaurus/src/commands/deploy.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/docusaurus/src/commands/deploy.ts b/packages/docusaurus/src/commands/deploy.ts index cb1c00ad700e..e98f01bdec5e 100644 --- a/packages/docusaurus/src/commands/deploy.ts +++ b/packages/docusaurus/src/commands/deploy.ts @@ -259,7 +259,9 @@ You can also set the deploymentBranch property in docusaurus.config.js .`); if ( shellExecLog(`git push --force origin ${deploymentBranch}`).code !== 0 ) { - throw new Error('Running "git push" command failed.'); + throw new Error( + 'Running "git push" command failed. Does the GitHub user account you are using have push access to the repository?', + ); } else if (commitResults.code === 0) { // The commit might return a non-zero value when site is up to date. let websiteURL = '';