Skip to content

Commit c72b2eb

Browse files
authored
ci: use a github app for token generation (#4014)
1 parent d1d8c26 commit c72b2eb

File tree

1 file changed

+10
-18
lines changed

1 file changed

+10
-18
lines changed

.github/workflows/changesets-version.yml

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,6 @@ jobs:
1111
name: Create Version Bump PR
1212
runs-on: ubuntu-latest
1313

14-
# Remove this once we setup react-native-sdk[bot] with this repo
15-
permissions:
16-
contents: write # for GH releases and Git tags (Changesets)
17-
pull-requests: write # version PRs (Changesets)
18-
1914
if: ${{ github.repository == 'microsoft/fluentui-react-native' }}
2015
steps:
2116
- name: Checkout
@@ -31,16 +26,15 @@ jobs:
3126
- name: Build packages
3227
run: yarn buildci
3328

34-
# Bring this back once we setup react-native-sdk[bot] with this repo
35-
# - name: Generate token for version PR
36-
# uses: actions/create-github-app-token@v2
37-
# id: app-token
38-
# with:
39-
# app-id: ${{ vars.APP_ID }}
40-
# private-key: ${{ secrets.PRIVATE_KEY }}
41-
# permissions: |
42-
# contents: write
43-
# pull-requests: write
29+
- name: Generate token for version PR
30+
uses: actions/create-github-app-token@v2
31+
id: app-token
32+
with:
33+
app-id: ${{ vars.APP_ID }}
34+
private-key: ${{ secrets.GH_APP_PRIVATE_KEY }}
35+
permissions: |
36+
contents: write
37+
pull-requests: write
4438
4539
- name: Create Version Bump PR
4640
id: changesets
@@ -49,6 +43,4 @@ jobs:
4943
version: yarn changeset:version
5044
createGithubReleases: false
5145
env:
52-
# Switch token once we setup react-native-sdk[bot] with this repo
53-
# GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
54-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
46+
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}

0 commit comments

Comments
 (0)