Skip to content

Commit

Permalink
Merge pull request #27 from emqx/20240813-ci-use-pat
Browse files Browse the repository at this point in the history
ci: fix sync workflow
  • Loading branch information
id authored Aug 13, 2024
2 parents 82692ca + 07229b7 commit ba2fa32
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/sync-en-doc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,18 @@ jobs:
name: "emqx-enterprise-schema-dump"
repository: ${{ env.REPOSITORY }}
run-id: ${{ env.RUN_ID }}
github-token: ${{ secrets.PAT_RO_WORKFLOWS }}

- name: Create PR to update desc.en.hocon
env:
GH_TOKEN: ${{ github.token }}
run: |
set -euxo pipefail
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
BASE_BRANCH="$(echo v$(echo $EMQX_VERSION | awk -F. '{print $1$2}'))"
NEW_BRANCH="sync-${EMQX_VERSION}"
git fetch origin
git checkout -b ${NEW_BRANCH} --track origin/${BASE_BRANCH}
cp _build/docgen/emqx-enterprise/desc.en.hocon ./
git add desc.en.hocon
Expand Down

0 comments on commit ba2fa32

Please sign in to comment.