mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-12-01 23:24:21 +08:00
1331b65023
Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much. - Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs [Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/) Signed-off-by: naveen <172697+naveensrinivasan@users.noreply.github.com>
26 lines
680 B
YAML
26 lines
680 B
YAML
name: 'Lock threads'
|
|
|
|
on:
|
|
schedule:
|
|
- cron: '0 18 * * 1'
|
|
# │ │ │ │ │
|
|
# min 0-59 ┘ │ │ │ └ weekday 0-6
|
|
# hour 0-23 ┘ │ └ month 1-12
|
|
# └ day 1-31
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
lock:
|
|
permissions:
|
|
issues: write # for dessant/lock-threads to lock issues
|
|
pull-requests: write # for dessant/lock-threads to lock PRs
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: dessant/lock-threads@v2
|
|
with:
|
|
github-token: ${{ github.token }}
|
|
issue-lock-inactive-days: '365'
|
|
pr-lock-inactive-days: '365'
|
|
issue-exclude-labels: 'question, needs more info'
|