Skip to content

Commit 4a8c6dd

Browse files
committed
update how to add label
1 parent 30e9739 commit 4a8c6dd

File tree

1 file changed

+5
-12
lines changed

1 file changed

+5
-12
lines changed

.github/workflows/pr-file-check.yml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,6 @@ jobs:
1414
name: 'Check for changed files'
1515
runs-on: ubuntu-latest
1616
steps:
17-
- name: 'Add "issue-please" label'
18-
if: github.event.action == 'opened'
19-
uses: actions/github-script@v6
20-
with:
21-
script: |
22-
github.rest.issues.addLabels({
23-
owner: context.repo.owner,
24-
repo: context.repo.repo,
25-
issue_number: context.issue.number,
26-
labels: ['issue-please']
27-
})
28-
2917
- name: 'package-lock.json matches package.json'
3018
uses: brettcannon/[email protected]
3119
with:
@@ -53,6 +41,11 @@ jobs:
5341
skip-label: 'skip tests'
5442
failure-message: 'TypeScript code was edited without also editing a ${file-pattern} file; see the Testing page in our wiki on testing guidelines (the ${skip-label} label can be used to pass this check)'
5543

44+
- name: Add "issue-please" Label
45+
uses: actions-ecosystem/action-add-labels@v1
46+
with:
47+
github_token: ${{ secrets.GITHUB_TOKEN }}
48+
labels: 'issue-please'
5649
- name: 'Ensure PR has an associated issue'
5750
uses: actions/github-script@v6
5851
with:

0 commit comments

Comments
 (0)