File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -19,10 +19,13 @@ jobs:
1919 steps :
2020 - name : Check for any changed workflows
2121 id : check-for-changed-workflows
22- uses : tj-actions/changed-files@v41
23- with :
24- files : |
25- .github/workflows/**.yml
22+ run : |
23+ CHANGED_WORKFLOWS=$(gh api repos/${{ github.event.pull_request.base.repo.full_name }}/pulls/${{ github.event.pull_request.number }}/files --jq '.[] | select((.filename | match("^.github/workflows/.*.yml$")) and (.status != "removed")) | .filename')
24+ if [[ -n "$CHANGED_WORKFLOWS" ]]; then
25+ echo "any_changed=true" >> $GITHUB_OUTPUT
26+ else
27+ echo "any_changed=false" >> $GITHUB_OUTPUT
28+ fi
2629 - name : Validate workflows
2730 if : steps.check-for-changed-workflows.outputs.any_changed == 'true'
2831 uses : dsanders11/json-schema-validate-action
You can’t perform that action at this time.
0 commit comments