Skip to content

Commit 32dffbc

Browse files
authored
Run link checks on modified files on push too (#10558)
1 parent 0ea7c11 commit 32dffbc

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/_link_check.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ jobs:
1818
script: |
1919
./scripts/lint_urls.sh $(
2020
[ "${{ github.event_name }}" = "pull_request" ] \
21-
&& git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}
21+
&& git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} \
22+
|| [ "${{ github.event_name }}" = "push" ] \
23+
&& git diff --name-only ${{ github.event.before }} ${{ github.sha }}
2224
)
2325
2426
lint-xrefs:
@@ -33,5 +35,7 @@ jobs:
3335
script: |
3436
./scripts/lint_xrefs.sh $(
3537
[ "${{ github.event_name }}" = "pull_request" ] \
36-
&& git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}
38+
&& git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} \
39+
|| [ "${{ github.event_name }}" = "push" ] \
40+
&& git diff --name-only ${{ github.event.before }} ${{ github.sha }}
3741
)

0 commit comments

Comments
 (0)