Skip to content

Commit 37b062b

Browse files
authored
Update _link_check.yml
1 parent 55f04e7 commit 37b062b

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

.github/workflows/_link_check.yml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,11 @@ jobs:
1818
timeout: 90
1919
script: |
2020
./scripts/lint_urls.sh $(
21-
[ "${{ github.event_name }}" = "pull_request" ] \
22-
&& git diff --name-only ${{ github.event.pull_request.base.sha }}...${{ github.event.pull_request.head.sha }} \
23-
|| [ "${{ github.event_name }}" = "push" ] \
24-
&& git diff --name-only ${{ github.event.before }}...${{ github.sha }}
21+
{ [ "${{ github.event_name }}" = "pull_request" ] \
22+
&& git diff --name-only "${{ github.event.pull_request.base.sha }}...${{ github.event.pull_request.head.sha }}"; } \
23+
|| \
24+
{ [ "${{ github.event_name }}" = "push" ] \
25+
&& git diff --name-only "${{ github.event.before }}...${{ github.sha }}"; }
2526
)
2627
2728
lint-xrefs:
@@ -36,8 +37,9 @@ jobs:
3637
timeout: 90
3738
script: |
3839
./scripts/lint_xrefs.sh $(
39-
[ "${{ github.event_name }}" = "pull_request" ] \
40-
&& git diff --name-only ${{ github.event.pull_request.base.sha }}...${{ github.event.pull_request.head.sha }} \
41-
|| [ "${{ github.event_name }}" = "push" ] \
42-
&& git diff --name-only ${{ github.event.before }}...${{ github.sha }}
40+
{ [ "${{ github.event_name }}" = "pull_request" ] \
41+
&& git diff --name-only "${{ github.event.pull_request.base.sha }}...${{ github.event.pull_request.head.sha }}"; } \
42+
|| \
43+
{ [ "${{ github.event_name }}" = "push" ] \
44+
&& git diff --name-only "${{ github.event.before }}...${{ github.sha }}"; }
4345
)

0 commit comments

Comments
 (0)