Skip to content

Commit 8a0d567

Browse files
authored
fix: permissions for PR labeler GH action workflow (#236)
Signed-off-by: Vladislav Doster <[email protected]>
1 parent 08c7053 commit 8a0d567

File tree

2 files changed

+16
-20
lines changed

2 files changed

+16
-20
lines changed

.github/labeler.yml

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,6 @@
1-
# Add 'zinit` label to any change in a zinit file
2-
zinit:
3-
- zinit*.zsh
4-
# Add 'scripts` label to any change in scripts/ directory
5-
scripts:
6-
- scripts/*
7-
# Add 'docs` label to any change in doc/ directory
8-
docs:
9-
- docs/*
10-
- doc/**/*
11-
# Add 'tests` label to any change in tests/ directory
12-
tests:
13-
- tests/*
14-
ci/cd:
15-
- .github/*
16-
- .github/**/*
1+
ci/cd: ['.github/**/*']
2+
docker: ['docker/*']
3+
docs: ['doc/**/*']
4+
scripts: ['scripts/*']
5+
tests: ['tests/**/*', '.zunit.yml']
6+
zinit: ['zinit*.zsh', '_zinit']
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,24 @@
1-
# This workflow will triage pull requests and apply a label based on the
2-
# paths that are modified in the pull request.
1+
# This workflow will triage pull requests and apply a label based on the paths
2+
# that are modified in the pull request.
33

44
name: Labeler
5-
on: [pull_request]
5+
6+
on:
7+
pull_request:
8+
branches:
9+
- main
610

711
jobs:
812
label-pull-requests:
913

10-
runs-on: ubuntu-latest
1114
permissions:
1215
contents: read
1316
pull-requests: write
1417

18+
runs-on: ubuntu-latest
19+
1520
steps:
1621
- uses: actions/labeler@v4
1722
with:
1823
repo-token: "${{ secrets.GITHUB_TOKEN }}"
24+
sync-labels: true

0 commit comments

Comments
 (0)