Skip to content

Commit

Permalink
Merge pull request #3705 from SuperITMan/bugfix/fix-git-user-info-for…
Browse files Browse the repository at this point in the history
…-ghpages-deployment

ci(build-main): fix git user information in gh-deploy.sh script
  • Loading branch information
SuperITMan committed Jan 24, 2024
2 parents 743bbb7 + 591d7ec commit 11a83ec
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions gh-deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -193,12 +193,6 @@ fi

logTrace "Version for which we are producing docs: ${DOCS_VERSION}"

if [[ ${GITHUB_ACTIONS} == true ]]; then
logTrace "Configuring Git for GitHub Actions"
git config user.name ${COMMIT_AUTHOR_USERNAME}
git config user.email ${COMMIT_AUTHOR_EMAIL}
fi

if [[ ${GH_ACTIONS_TAG} =~ .*-(alpha|beta|rc).* ]]; then
logTrace "This is a pre-release version, we will publish the docs under the 'next' folder"
LATEST_DIR_NAME="next"
Expand Down Expand Up @@ -263,6 +257,13 @@ logInfo "Pushing the docs to GitHub pages"

cd ${DOCS_WORK_DIR}
git add -A &> /dev/null # way too long

if [[ ${GITHUB_ACTIONS} == true ]]; then
logTrace "Configuring Git for GitHub Actions"
git config user.name ${COMMIT_AUTHOR_USERNAME}
git config user.email ${COMMIT_AUTHOR_EMAIL}
fi

git commit --quiet -m "Publishing docs for version: ${DOCS_VERSION}"
git push --quiet --force
cd - > /dev/null
Expand Down

0 comments on commit 11a83ec

Please sign in to comment.