|
1 | | -name: Stale |
| 1 | +#name: Stale |
2 | 2 |
|
3 | 3 | # **What it does**: Close issues and pull requests after no updates for 365 days. |
4 | 4 | # **Why we have it**: We want to manage our queue of issues and pull requests. |
5 | 5 | # **Who does it impact**: Everyone that works on docs or docs-internal. |
6 | 6 |
|
| 7 | +#on: |
| 8 | + #schedule: |
| 9 | + # - cron: '20 16 * * *' # Run every day at 16:20 UTC / 8:20 PST |
| 10 | + |
| 11 | +#permissions: |
| 12 | + #contents: read |
| 13 | + #issues: write |
| 14 | + #pull-requests: write |
| 15 | + |
| 16 | +#jobs: |
| 17 | + #stale: |
| 18 | + #if: github.repository == 'github/docs-internal' || github.repository == 'github/docs' |
| 19 | + #runs-on: ubuntu-latest |
| 20 | + #steps: |
| 21 | + #- uses: actions/stale@28ca1036281a5e5922ead5184a1bbf96e5fc984e # v9.0.0 |
| 22 | + #with: |
| 23 | + #repo-token: ${{ secrets.GITHUB_TOKEN }} |
| 24 | + #stale-issue-message: 'This issue is stale because there have been no updates in 365 days.' |
| 25 | + #stale-pr-message: 'This PR is stale because there have been no updates in 365 days.' |
| 26 | + #days-before-stale: 365 |
| 27 | + #days-before-close: 0 |
| 28 | + #stale-issue-label: 'stale' |
| 29 | + #stale-pr-label: 'stale' |
| 30 | + #exempt-pr-labels: 'never-stale,waiting for review' |
| 31 | + #exempt-issue-labels: 'never-stale,help wanted,waiting for review' |
| 32 | + #operations-per-run: 1000 |
| 33 | + #close-issue-reason: not_planned |
| 34 | + |
| 35 | + #- name: Check out repo |
| 36 | + #if: ${{ failure() }} |
| 37 | + #uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 |
| 38 | + #- uses: ./.github/actions/slack-alert |
| 39 | + #if: ${{ failure() }} |
| 40 | + #with: |
| 41 | + #slack_channel_id: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }} |
| 42 | + #slack_token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }} |
| 43 | + |
| 44 | +name: 'Marks stale issues and PRs' |
7 | 45 | on: |
8 | 46 | schedule: |
9 | | - - cron: '20 16 * * *' # Run every day at 16:20 UTC / 8:20 PST |
| 47 | + - cron: '30 1 * * *' # 1:30 AM UTC |
10 | 48 |
|
11 | 49 | permissions: |
12 | | - contents: read |
13 | 50 | issues: write |
14 | | - pull-requests: write |
15 | 51 |
|
16 | 52 | jobs: |
17 | 53 | stale: |
18 | | - if: github.repository == 'github/docs-internal' || github.repository == 'github/docs' |
19 | 54 | runs-on: ubuntu-latest |
20 | 55 | steps: |
21 | | - - uses: actions/stale@28ca1036281a5e5922ead5184a1bbf96e5fc984e # v9.0.0 |
| 56 | + - uses: actions/stale@v9 |
22 | 57 | with: |
23 | | - repo-token: ${{ secrets.GITHUB_TOKEN }} |
24 | | - stale-issue-message: 'This issue is stale because there have been no updates in 365 days.' |
25 | | - stale-pr-message: 'This PR is stale because there have been no updates in 365 days.' |
| 58 | + stale-issue-label: 'stale, triage' # The label that will be added to the issues when automatically marked as stale |
| 59 | + start-date: '2024-11-25T00:00:00Z' # Skip stale action for issues/PRs created before it |
26 | 60 | days-before-stale: 365 |
27 | | - days-before-close: 0 |
28 | | - stale-issue-label: 'stale' |
29 | | - stale-pr-label: 'stale' |
30 | | - exempt-pr-labels: 'never-stale,waiting for review' |
31 | | - exempt-issue-labels: 'never-stale,help wanted,waiting for review' |
32 | | - operations-per-run: 1000 |
33 | | - close-issue-reason: not_planned |
34 | | - |
35 | | - - name: Check out repo |
36 | | - if: ${{ failure() }} |
37 | | - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 |
38 | | - - uses: ./.github/actions/slack-alert |
39 | | - if: ${{ failure() }} |
40 | | - with: |
41 | | - slack_channel_id: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }} |
42 | | - slack_token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }} |
| 61 | + days-before-close: -1 # If -1, the issues nor pull requests will never be closed automatically. |
| 62 | + days-before-pr-stale: -1 # If -1, no pull requests will be marked as stale automatically. |
| 63 | + exempt-issue-labels: 'never-stale, help wanted, ' # issues labeled as such will be excluded them from being marked as stale |
0 commit comments