Skip to content

Commit 173ecdb

Browse files
authored
Replace archived action with actions/create-github-app-token@v2 (maplibre#3652)
1 parent f332198 commit 173ecdb

3 files changed

Lines changed: 22 additions & 14 deletions

File tree

.github/workflows/android-device-test.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -100,12 +100,12 @@ jobs:
100100
id: get-pr-number
101101

102102
- name: Generate token
103+
uses: actions/create-github-app-token@v2
103104
id: generate_token
104-
uses: tibdex/github-app-token@v2
105105
with:
106-
revoke: false # revoking will fail for long running workflows, because the token will already have expired
107-
app_id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
108-
private_key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
106+
skip-token-revoke: true # revoking will fail for long running workflows, because the token will already have expired
107+
app-id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
108+
private-key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
109109

110110
- name: Check if comment on PR contains '!benchmark android'
111111
if: matrix.test.name == 'Android Benchmark' && steps.get-pr-number.outputs.pr-number
@@ -203,11 +203,11 @@ jobs:
203203

204204
- name: Generate another token (previous one could have expired)
205205
if: always()
206+
uses: actions/create-github-app-token@v2
206207
id: generate_token_2
207-
uses: tibdex/github-app-token@v2
208208
with:
209-
app_id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
210-
private_key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
209+
app-id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
210+
private-key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
211211

212212
- uses: LouisBrunner/checks-action@v2.0.0
213213
if: always()

.github/workflows/ios-ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -333,11 +333,11 @@ jobs:
333333
# needed to trigger workflow for Swift Package Index release
334334
- name: Generate token
335335
if: env.make_release
336+
uses: actions/create-github-app-token@v2
336337
id: generate_token
337-
uses: tibdex/github-app-token@v2
338338
with:
339-
app_id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
340-
private_key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
339+
app-id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
340+
private-key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
341341

342342
- name: Release (Swift Package Index)
343343
if: env.make_release

.github/workflows/ios-device-test.yml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ jobs:
2424
- uses: actions/checkout@v4
2525

2626
- name: Generate token
27+
uses: actions/create-github-app-token@v2
2728
id: generate_token
28-
uses: tibdex/github-app-token@v2
2929
with:
30-
app_id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
31-
private_key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
30+
app-id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
31+
private-key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
3232

3333
- uses: LouisBrunner/checks-action@v2.0.0
3434
id: create_check
@@ -72,10 +72,18 @@ jobs:
7272
7373
./scripts/aws-device-farm/aws-device-farm-run.sh
7474
75+
- name: Generate another token (previous one could have expired)
76+
if: always()
77+
uses: actions/create-github-app-token@v2
78+
id: generate_token_2
79+
with:
80+
app-id: ${{ secrets.MAPLIBRE_NATIVE_BOT_APP_ID }}
81+
private-key: ${{ secrets.MAPLIBRE_NATIVE_BOT_PRIVATE_KEY }}
82+
7583
- uses: LouisBrunner/checks-action@v2.0.0
7684
if: always()
7785
with:
78-
token: ${{ steps.generate_token.outputs.token }}
86+
token: ${{ steps.generate_token_2.outputs.token }}
7987
check_id: ${{ steps.create_check.outputs.check_id }}
8088
conclusion: ${{ job.status }}
8189
sha: ${{ github.event.workflow_run.sha }}

0 commit comments

Comments
 (0)