diff --git a/.github/workflows/update_api.yml b/.github/workflows/update_api.yml index d3c46aa7..bbcb0205 100644 --- a/.github/workflows/update_api.yml +++ b/.github/workflows/update_api.yml @@ -44,7 +44,7 @@ jobs: id: cpr uses: peter-evans/create-pull-request@v4 with: - token: ${{ secrets.GITHUB_TOKEN }} + token: ${{ steps.github_app_token.outputs.token || secrets.GITHUB_TOKEN }} commit-message: Update API from slack-api-ref@${{ steps.api-ref.outputs.api-ref }} (${{ steps.date.outputs.date }}) title: Update API from slack-api-ref@${{ steps.api-ref.outputs.api-ref }} body: | @@ -61,15 +61,12 @@ jobs: include: CHANGELOG.md find: "\\* Your contribution here." replace: "* [#${{steps.cpr.outputs.pull-request-number}}](https://github.com/slack-ruby-client/pulls/${{steps.cpr.outputs.pull-request-number}}): Update API from [slack-api-ref@${{ steps.api-ref.outputs.api-ref }}](https://github.com/slack-ruby/slack-api-ref/commit/${{ steps.api-ref.outputs.api-ref }}) - [@slack-ruby-ci-bot](https://github.com/apps/slack-ruby-ci-bot).\n* Your contribution here." - - name: push - uses: dblock/commit@edcd15e90878df73c18a5bbdcd5755f10be8baa0 - with: - github-token: ${{ steps.github_app_token.outputs.token }} - push-branch: 'automated-api-update' - commit-message: Update API from slack-api-ref@${{ steps.api-ref.outputs.api-ref }} (${{ steps.date.outputs.date }}) - commit-amend: true - force-add: true - force-push: true - files: CHANGELOG.md - name: slack-ruby-ci-bot - email: noreply@github.com + - name: Commit and Push + run: | + git config --local user.name 'slack-ruby-ci-bot' + git config --local user.email 'noreply@github.com' + git config --local --unset http.https://github.com/.extraheader ^AUTHORIZATION: + git config --local http.https://github.com/.extraheader AUTHORIZATION: basic x-access-token:${{ steps.github_app_token.outputs.token || secrets.GITHUB_TOKEN }} + git add CHANGELOG.md + git commit --amend --no-edit + git push origin automated-api-update -f