Skip to content

Commit d5fc190

Browse files
authored
ci: publish releases using the @slackapi github app token (#2560)
1 parent 2e0395b commit d5fc190

1 file changed

Lines changed: 12 additions & 1 deletion

File tree

.github/workflows/release.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,21 @@ jobs:
5151
contents: write
5252
id-token: write # OIDC: https://docs.npmjs.com/trusted-publishers
5353
steps:
54+
- name: Gather credentials
55+
id: credentials
56+
uses: actions/create-github-app-token@1b10c78c7865c340bc4f6099eb2f838309f1e8c3 # v3.1.1
57+
with:
58+
client-id: ${{ secrets.GH_APP_CLIENT_ID }}
59+
private-key: ${{ secrets.GH_APP_PRIVATE_KEY }}
60+
owner: ${{ github.repository_owner }}
61+
repositories: ${{ github.event.repository.name }}
62+
permission-contents: write
63+
5464
- name: Checkout repo
5565
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
5666
with:
5767
persist-credentials: true
68+
token: ${{ steps.credentials.outputs.token }}
5869

5970
- name: Setup Node
6071
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
@@ -86,4 +97,4 @@ jobs:
8697
createGithubReleases: true
8798
publish: npm run changeset -- publish
8899
env:
89-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
100+
GITHUB_TOKEN: ${{ steps.credentials.outputs.token }}

0 commit comments

Comments
 (0)