Skip to content

Commit 7c3f185

Browse files
committed
Update check-restricted-files.yaml
1 parent 7fe9777 commit 7c3f185

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

.github/workflows/check-restricted-files.yaml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,8 @@ name: check-restricted-files
55

66
# This workflow checks for changes of restricted files in a pull request
77

8-
# run this on push to any branch and creation or review of pull-requests
98
on:
10-
# - push
119
- pull_request
12-
# - pull_request_review
1310

1411
jobs:
1512
check-files:
@@ -21,13 +18,12 @@ jobs:
2118
fetch-depth: 0
2219

2320
- name: Check changed files
24-
id: check-changes
2521
shell: bash
2622
run: |
2723
# TODO: skip if base.ref is main
2824
2925
git diff --exit-code --name-only ${{ github.event.pull_request.head.sha }} ${{ github.event.pull_request.base.sha }} -- schemas versions
30-
if [ $? -ne 0 ]; then
26+
if [[ $? -ne 0 ]]; then
3127
echo This PR contains changes to files that should not be changed on ${{ github.event.pull_request.base.ref }}
3228
exit 1
33-
fi
29+
fi

0 commit comments

Comments
 (0)