Skip to content

Commit

Permalink
ci: lock closed issues automatically after 90 days
Browse files Browse the repository at this point in the history
  • Loading branch information
tulir committed Nov 13, 2024
1 parent 024577d commit 0d148ff
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: 'Lock old issues'

on:
schedule:
- cron: '0 21 * * *'
workflow_dispatch:

permissions:
issues: write
# pull-requests: write
# discussions: write

concurrency:
group: lock-threads

jobs:
lock-stale:
runs-on: ubuntu-latest
steps:
- uses: dessant/lock-threads@v5
id: lock
with:
issue-inactive-days: 90
process-only: issues
- name: Log processed threads
run: |
if [ '${{ steps.lock.outputs.issues }}' ]; then
echo "Issues:" && echo '${{ steps.lock.outputs.issues }}' | jq -r '.[] | "https://github.com/\(.owner)/\(.repo)/issues/\(.issue_number)"'
fi

0 comments on commit 0d148ff

Please sign in to comment.