From cef5cb9c8df99ef467953cd735309fe0b470be6e Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 4 Jan 2024 09:44:02 +0800 Subject: [PATCH] Revert the changes in format-command.yml --- .github/workflows/format-command.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/format-command.yml b/.github/workflows/format-command.yml index 5e31c483627..0cdad84b468 100644 --- a/.github/workflows/format-command.yml +++ b/.github/workflows/format-command.yml @@ -10,10 +10,17 @@ jobs: format: runs-on: ubuntu-latest steps: + # Generate token from GenericMappingTools bot + - uses: tibdex/github-app-token@v2 + id: generate-token + with: + app_id: ${{ secrets.APP_ID }} + private_key: ${{ secrets.APP_PRIVATE_KEY }} + # Checkout the pull request branch - uses: actions/checkout@v4.1.1 with: - token: ${{ secrets.GITHUB_TOKEN }} + token: ${{ steps.generate-token.outputs.token }} repository: ${{ github.event.client_payload.pull_request.head.repo.full_name }} ref: ${{ github.event.client_payload.pull_request.head.ref }} @@ -45,7 +52,7 @@ jobs: - name: Add reaction uses: peter-evans/create-or-update-comment@v3.1.0 with: - token: ${{ secrets.GITHUB_TOKEN }} + token: ${{ steps.generate-token.outputs.token }} repository: ${{ github.event.client_payload.github.payload.repository.full_name }} comment-id: ${{ github.event.client_payload.github.payload.comment.id }} reactions: hooray