name: Stale
on:
  schedule:
    - cron: "30 1 * * *"
  workflow_dispatch:

permissions:
  actions: write
  issues: write

jobs:
  stale:
    name: Close Stale Issues
    runs-on: ubuntu-latest
    steps:
      - name: Mark and close stale issues
        uses: actions/stale@v10
        with:
          stale-issue-label: Stale
          only-labels: "Needs Info"
          days-before-stale: 30
          stale-issue-message: >
            This issue has been waiting for information for 30 days.
            It will be closed in 7 days if there is no further activity.
            Feel free to reopen if you can provide the requested details.
          close-issue-message: >
            Closed due to inactivity. Feel free to reopen with the
            requested information.
          days-before-pr-stale: -1
          days-before-pr-close: -1
