Skip to content

Commit 32252ee

Browse files
committed
Set permissions to the actions
This commit update the actions "Auto Assign Author" and "Auto Label PRs" Signed-off-by: Daniel Jiang <daniel.jiang@broadcom.com>
1 parent 1160ae2 commit 32252ee

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

.github/workflows/auto_assign_prs.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
pull_request_target:
88
types: [opened, reopened, ready_for_review]
99

10+
permissions:
11+
contents: read
12+
pull-requests: write
13+
1014
jobs:
1115
# Automatically assigns reviewers and owner
1216
add-reviews:
@@ -16,4 +20,3 @@ jobs:
1620
uses: kentaro-m/auto-assign-action@v2.0.0
1721
with:
1822
configuration-path: ".github/auto-assignees.yml"
19-
repo-token: "${{ secrets.GITHUB_TOKEN }}"

.github/workflows/auto_label_prs.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,15 @@ on:
88
pull_request_target:
99
types: [opened, reopened, synchronize, ready_for_review]
1010

11+
permissions:
12+
contents: read
13+
pull-requests: write
14+
1115
jobs:
1216
# Automatically labels PRs based on file globs in the change.
1317
triage:
1418
runs-on: ubuntu-latest
1519
steps:
1620
- uses: actions/labeler@v5
1721
with:
18-
repo-token: "${{ secrets.GITHUB_TOKEN }}"
1922
configuration-path: .github/labeler.yml

0 commit comments

Comments
 (0)