Skip to content

Commit 4cecc87

Browse files
authored
ci: replace OCTOKITBOT_PROJECT_ACTION_TOKEN and OCTOKITBOT_PAT with a token from https://github.com/apps/octokit (#117)
1 parent c84b5df commit 4cecc87

File tree

3 files changed

+19
-2
lines changed

3 files changed

+19
-2
lines changed

.github/workflows/add-to-octokit-project.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,15 @@ jobs:
1212
runs-on: ubuntu-latest
1313
continue-on-error: true
1414
steps:
15+
- uses: actions/create-github-app-token@v1
16+
id: app-token
17+
with:
18+
app-id: ${{ vars.OCTOKIT_APP_ID }}
19+
private-key: ${{ secrets.OCTOKIT_APP_PRIVATE_KEY }}
20+
owner: octokit
1521
- uses: actions/[email protected]
1622
with:
1723
project-url: https://github.com/orgs/octokit/projects/10
18-
github-token: ${{ secrets.OCTOKITBOT_PROJECT_ACTION_TOKEN }}
24+
github-token: ${{ steps.app-token.outputs.token }}
1925
labeled: "Status: Stale"
2026
label-operator: NOT

.github/workflows/immediate-response.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@ jobs:
1414
if: ${{ github.actor != 'dependabot[bot]' && github.actor != 'renovate[bot]' && github.actor != 'githubactions[bot]' && github.actor != 'octokitbot' }}
1515
runs-on: ubuntu-latest
1616
steps:
17+
- uses: actions/create-github-app-token@v1
18+
id: app-token
19+
with:
20+
app-id: ${{ vars.OCTOKIT_APP_ID }}
21+
private-key: ${{ secrets.OCTOKIT_APP_PRIVATE_KEY }}
1722
- name: Determine issue or PR number
1823
id: extract
1924
run: echo "NUMBER=${{ github.event.issue.number || github.event.pull_request.number }}" >> "$GITHUB_OUTPUT"
@@ -27,3 +32,4 @@ jobs:
2732
We have a [process in place](https://github.com/octokit/.github/blob/main/community/prioritization_response.md#overview) for prioritizing and responding to your input.
2833
Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labled with `Status: Up for grabs`.
2934
You & others like you are the reason all of this works! So thank you & happy coding! 🚀
35+
token: ${{ steps.app-token.outputs.token }}

.github/workflows/update.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ jobs:
1111
# These steps should be kept in sync with `update_dry_run.yml` - minus the code that
1212
# actually commits, pushes and creates a PR.
1313
steps:
14+
- uses: actions/create-github-app-token@v1
15+
id: app-token
16+
with:
17+
app-id: ${{ vars.OCTOKIT_APP_ID }}
18+
private-key: ${{ secrets.OCTOKIT_APP_PRIVATE_KEY }}
1419
- uses: actions/checkout@v4
1520
- uses: actions/setup-node@v4
1621
with:
@@ -33,7 +38,7 @@ jobs:
3338
- name: update cache
3439
uses: gr2m/[email protected]
3540
env:
36-
GITHUB_TOKEN: ${{ secrets.OCTOKITBOT_PAT }}
41+
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
3742
with:
3843
title: 🤖📯 GitHub OpenAPI Update
3944
body: >

0 commit comments

Comments
 (0)