File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88
99 steps :
1010 - uses : actions/checkout@v4
11+ with :
12+ fetch-depth : 0
13+
14+ - name : Get changed files
15+ id : changed-files
16+ uses : tj-actions/changed-files@v44
17+ with :
18+ files : |
19+ **/*.md
20+ **/*.html
21+ **/*.json
22+ separator : " "
1123
12- - name : Check links
24+ - name : Check links in changed files
1325 id : lychee
26+ if : steps.changed-files.outputs.any_changed == 'true'
1427 uses : lycheeverse/lychee-action@v2
1528 with :
1629 fail : false
1730 format : " json"
1831 output : " results.json"
1932 args : |
20- --include '.*\.md$'
21- --include '.*\.html$'
2233 --verbose
23- .
34+ ${{ steps.changed-files.outputs.all_changed_files }}
35+
36+ - name : Create empty results if no files changed
37+ if : steps.changed-files.outputs.any_changed == 'false'
38+ run : echo '[]' > results.json
2439
2540 - name : Publish link check report
2641 uses : mikepenz/action-junit-report@v6
You can’t perform that action at this time.
0 commit comments