Skip to content

Commit add1a33

Browse files
authored
feat: Action to comment & close issues based on label (#15640)
1 parent 7cd485b commit add1a33

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/not-this-repo.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Add comment & close
2+
on:
3+
issues:
4+
types:
5+
- labeled
6+
jobs:
7+
add-comment:
8+
if: github.event.label.name == 'not-this-repo'
9+
runs-on: ubuntu-latest
10+
permissions:
11+
issues: write
12+
steps:
13+
- name: Add comment
14+
run: gh issue close "$NUMBER" --reason "not planned" --comment "$BODY"
15+
env:
16+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
17+
GH_REPO: ${{ github.repository }}
18+
NUMBER: ${{ github.event.issue.number }}
19+
BODY: >
20+
Hi, this issue tracker is for issues with the codebase behind pypi.org itself,
21+
not the projects hosted on PyPI.
22+
23+
You should report this issue to the tracker for the project in question instead.

0 commit comments

Comments
 (0)