Skip to content

Commit 6f25f33

Browse files
committed
Add workflow call trigger and permissions for CoC rollout.
1 parent 3431b4a commit 6f25f33

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.github/workflows/coc-update.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
push:
55
branches: ['main']
66
paths: ['CODE_OF_CONDUCT.md']
7+
workflow_call:
78

89
defaults:
910
run:
@@ -12,6 +13,8 @@ defaults:
1213
jobs:
1314
plan-coc-update:
1415
runs-on: ubuntu-latest
16+
permissions:
17+
contents: read
1518
outputs:
1619
repo_list: ${{ steps.repo_list.outputs.repo_list }}
1720
commit_hash: ${{ steps.commit_hash.outputs.commit_hash }}
@@ -25,6 +28,8 @@ jobs:
2528
echo "commit_hash=$commit_hash" >> $GITHUB_OUTPUT
2629
- name: Get list of repositories
2730
id: repo_list
31+
env:
32+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2833
run: |
2934
repo_list=$(gh repo list $GITHUB_REPOSITORY_OWNER --no-archived --json nameWithOwner --jq ".[].nameWithOwner")
3035
echo "repo_list=$repo_list" >> $GITHUB_OUTPUT

0 commit comments

Comments
 (0)