Skip to content

Commit 655e079

Browse files
ci: Fix CodeQL scanning alerts (#278)
1 parent 9faa2d3 commit 655e079

File tree

4 files changed

+18
-3
lines changed

4 files changed

+18
-3
lines changed

.github/workflows/check-pr.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ on:
1010
push:
1111
branches:
1212
- next
13+
permissions:
14+
contents: read
1315
env:
1416
HUSKY: 0
1517
jobs:

.github/workflows/merge-to-main.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,17 @@ name: Attempt to merge next to main
22
on:
33
workflow_dispatch:
44

5+
permissions:
6+
contents: read
7+
58
jobs:
69
# Check if next can merge into main
710
perform_merge:
811
name: Perform merge if "next" can merge into "main"
912
runs-on: ubuntu-latest
13+
permissions:
14+
contents: write #because we push - git push origin "main"
15+
pull-requests: write # PR updates
1016
steps:
1117
- name: Checkout
1218
uses: actions/checkout@v2
@@ -40,4 +46,4 @@ jobs:
4046

4147
steps:
4248
- name: Post error message (To-Do)
43-
run: echo "Next cannot be merged into main cleanly"
49+
run: echo "Next cannot be merged into main cleanly"

.github/workflows/merge-to-next-major.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,17 @@ on:
33
workflow_dispatch:
44
push:
55
branches:
6-
- "next"
6+
- 'next'
7+
permissions:
8+
contents: read
79

810
jobs:
911
# Check if next can merge into next-major
1012
perform_merge:
1113
name: Perform merge if "next" can merge into "next-major"
14+
permissions:
15+
contents: write #because we push - git push origin "next-major"
16+
pull-requests: write # PR updates
1217
runs-on: ubuntu-latest
1318
steps:
1419
- name: Checkout
@@ -69,4 +74,4 @@ jobs:
6974

7075
steps:
7176
- name: Post error message (To-Do)
72-
run: echo "Next cannot be merged into next-major cleanly"
77+
run: echo "Next cannot be merged into next-major cleanly"

.github/workflows/release.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ on:
55
branches:
66
- 'main'
77
- 'next'
8+
permissions:
9+
contents: read
810
env:
911
HUSKY: 0
1012
jobs:

0 commit comments

Comments
 (0)