ci: Run ktlint workflow on forks, with write permissions (#95)

Previously the permissions were only applied to branches from this
repository, not forks. Use `pull_request_target` so the `GITHUB_TOKEN`
will have the correct permissions when this workflow is run from a PR
created from a clone.

Remove the `issues` permission, it didn't seem necessary.
This commit is contained in:
Nik Clayton 2023-09-25 18:18:39 +02:00 committed by GitHub
parent 04025e99ff
commit f71a5e1237
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -1,9 +1,8 @@
name: reviewdog-suggester
on: pull_request
on: pull_request_target
permissions:
contents: read
issues: write
pull-requests: write
jobs: