Skip to content

Commit 368418d

Browse files
apply_labels.yml
1 parent 8172f4f commit 368418d

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/label.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Apply Label to New Issues
2+
on:
3+
issues:
4+
types: [opened]
5+
6+
jobs:
7+
label:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Apply Label
11+
uses: actions/github-script@v5
12+
with:
13+
github-token: ${{secrets.GITHUB_TOKEN}}
14+
script: |
15+
const issue = context.issue;
16+
github.rest.issues.addLabels({
17+
owner: issue.owner,
18+
repo: issue.repo,
19+
issue_number: issue.number,
20+
labels: ['✉️ github-invitation']
21+
});

0 commit comments

Comments
 (0)