mirror of
https://github.com/go-vikunja/vikunja.git
synced 2026-04-24 22:25:15 +00:00
chore(ci): use github app to handle issue closed comments
This commit is contained in:
11
.github/workflows/issue-closed-comment.yml
vendored
11
.github/workflows/issue-closed-comment.yml
vendored
@@ -8,11 +8,18 @@ jobs:
|
||||
comment-on-issue-closure:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Generate GitHub App token
|
||||
id: generate-token
|
||||
uses: actions/create-github-app-token@v1
|
||||
with:
|
||||
app-id: ${{ secrets.BOT_APP_ID }}
|
||||
private-key: ${{ secrets.BOT_APP_PRIVATE_KEY }}
|
||||
|
||||
- name: Check if issue was closed by commit
|
||||
id: check-commit
|
||||
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
github-token: ${{ steps.generate-token.outputs.token }}
|
||||
script: |
|
||||
const issueNumber = context.payload.issue.number;
|
||||
|
||||
@@ -56,7 +63,7 @@ jobs:
|
||||
if: steps.check-commit.outputs.closed_by_commit == 'true'
|
||||
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
github-token: ${{ steps.generate-token.outputs.token }}
|
||||
script: |
|
||||
const issueNumber = context.payload.issue.number;
|
||||
const commitSha = '${{ steps.check-commit.outputs.commit_sha }}';
|
||||
|
||||
Reference in New Issue
Block a user