Skip to content

Commit fc30b60

Browse files
committed
stale-issues-and-prs.yml: update to match main configuration
1 parent cbee874 commit fc30b60

1 file changed

Lines changed: 81 additions & 0 deletions

File tree

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# This file is synced from the `.github` repository, do not modify it directly.
2+
name: Manage stale issues and pull requests
3+
4+
on:
5+
push:
6+
paths:
7+
- .github/workflows/stale-issues-and-prs.yml
8+
branches-ignore:
9+
- dependabot/**
10+
schedule:
11+
# Once every day at midnight UTC
12+
- cron: "0 0 * * *"
13+
issue_comment:
14+
15+
permissions: {}
16+
17+
defaults:
18+
run:
19+
shell: bash -xeuo pipefail {0}
20+
21+
concurrency:
22+
group: stale-issues-and-prs
23+
cancel-in-progress: ${{ github.event_name != 'issue_comment' }}
24+
25+
jobs:
26+
stale:
27+
if: >
28+
github.repository_owner == 'Homebrew' && (
29+
github.event_name != 'issue_comment' || (
30+
contains(github.event.issue.labels.*.name, 'stale') ||
31+
contains(github.event.pull_request.labels.*.name, 'stale')
32+
)
33+
)
34+
runs-on: ubuntu-slim
35+
permissions:
36+
actions: write
37+
contents: write
38+
issues: write
39+
pull-requests: write
40+
steps:
41+
- name: Mark/Close Stale Issues and Pull Requests
42+
uses: actions/stale@eb5cf3af3ac0a1aa4c9c45633dd1ae542a27a899 # v10.3.0
43+
with:
44+
repo-token: ${{ secrets.GITHUB_TOKEN }}
45+
days-before-stale: 21
46+
days-before-close: 7
47+
stale-issue-message: >
48+
This issue has been automatically marked as stale because it has not had
49+
recent activity. It will be closed if no further activity occurs.
50+
stale-pr-message: >
51+
This pull request has been automatically marked as stale because it has not had
52+
recent activity. It will be closed if no further activity occurs.
53+
exempt-issue-labels: "help wanted"
54+
delete-branch: true
55+
56+
bump-pr-stale:
57+
if: >
58+
github.repository_owner == 'Homebrew' && (
59+
github.event_name != 'issue_comment' || (
60+
contains(github.event.issue.labels.*.name, 'stale') ||
61+
contains(github.event.pull_request.labels.*.name, 'stale')
62+
)
63+
)
64+
runs-on: ubuntu-slim
65+
permissions:
66+
actions: write
67+
contents: write
68+
issues: write
69+
pull-requests: write
70+
steps:
71+
- name: Mark/Close Stale `bump-formula-pr` and `bump-cask-pr` Pull Requests
72+
uses: actions/stale@eb5cf3af3ac0a1aa4c9c45633dd1ae542a27a899 # v10.3.0
73+
with:
74+
repo-token: ${{ secrets.GITHUB_TOKEN }}
75+
days-before-stale: 2
76+
days-before-close: 1
77+
stale-pr-message: >
78+
This pull request has been automatically marked as stale because it has not had
79+
recent activity. It will be closed if no further activity occurs.
80+
any-of-labels: "bump-formula-pr,bump-cask-pr"
81+
delete-branch: true

0 commit comments

Comments
 (0)