Skip to content

Commit 624b477

Browse files
authored
Merge pull request #4656 from dev-hato/massongit-patch-1
CI pr-format: GitHub Appのトークンを使う
2 parents c6e0784 + 3bab34e commit 624b477

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

.github/workflows/pr-format.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,20 @@ jobs:
1919
pr-format:
2020
runs-on: ubuntu-latest
2121
steps:
22+
- name: Generate a token
23+
id: generate_token
24+
uses: actions/create-github-app-token@c1a285145b9d317df6ced56c09f525b5c2b6f755 # v1.11.1
25+
with:
26+
app-id: ${{ secrets.PROJECT_AUTOMATION_APP_ID }}
27+
private-key: ${{ secrets.PROJECT_AUTOMATION_PRIVATE_KEY }}
2228
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2329
if: github.event_name != 'pull_request' || github.event.action != 'closed'
2430
with:
2531
# ここでsubmodule持ってくるとdetached headにcommitして死ぬ
2632
# submodule: 'recursive'
2733
fetch-depth: 0
2834
ref: ${{ github.event.pull_request.head.sha }}
35+
token: ${{steps.generate_token.outputs.token}}
2936
- name: Get uv version
3037
id: get_uv_version
3138
if: github.event_name != 'pull_request' || github.event.action != 'closed'
@@ -48,7 +55,7 @@ jobs:
4855
- uses: dev-hato/actions-diff-pr-management@cc201e3df74a342983025c4e97b7216b4e77f9f1 # v2.0.0
4956
if: success() || failure()
5057
with:
51-
github-token: ${{secrets.GITHUB_TOKEN}}
58+
github-token: ${{steps.generate_token.outputs.token}}
5259
branch-name-prefix: fix-format
5360
pr-title-prefix: formatが間違ってたので直してあげたよ!
5461
concurrency:

0 commit comments

Comments
 (0)