Skip to content

Commit

Permalink
chore: new token workflow for worker-deploy.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
gentlementlegen committed Dec 18, 2024
1 parent 821bb17 commit 616c99f
Showing 1 changed file with 1 addition and 20 deletions.
21 changes: 1 addition & 20 deletions .github/workflows/worker-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,25 +87,6 @@ jobs:
app-id: ${{ env.APP_ID }}
private-key: ${{ env.APP_PRIVATE_KEY }}

- name: Get GitHub App User ID
id: get-user-id
run: echo "user-id=$(gh api "/users/${{ steps.app-token.outputs.app-slug }}[bot]" --jq .id)" >> "$GITHUB_OUTPUT"
env:
GH_TOKEN: ${{ steps.app-token.outputs.token }}

- name: "Set GitHub user"
run: |
APP_SLUG="${{ steps.app-token.outputs.app-slug || 'github-actions' }}"
USER_ID="${{ steps.get-user-id.outputs.user-id || '' }}"
if [ -z "$USER_ID" ]; then
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
else
git config --global user.name "${APP_SLUG}[bot]"
git config --global user.email "${USER_ID}+${APP_SLUG}[bot]@users.noreply.github.com"
fi
- name: Format manifest.json using Prettier
shell: bash
run: |
Expand All @@ -119,7 +100,7 @@ jobs:
with:
files: |
manifest.json
commit-message: "chore: update manifest.json url"
commit-message: "chore: [skip ci] update manifest.json url"
ref: ${{ github.ref }}

- name: Write Deployment URL to Summary
Expand Down

0 comments on commit 616c99f

Please sign in to comment.