File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7676 - name : Get changed files
7777 id : changed-files
7878 uses : tj-actions/changed-files@v46
79+ with :
80+ files : |
81+ ${{ matrix.trigger_path }}
7982
8083 - name : Determine if this variant should run
8184 id : check
@@ -86,14 +89,11 @@ jobs:
8689 if [[ "${{ github.event.inputs.variant }}" == "all" || "${{ github.event.inputs.variant }}" == "${{ matrix.variant }}" ]]; then
8790 SHOULD_RUN=true
8891 fi
89- # For push triggers, check the changed files against the matrix path
92+ # For push triggers, use the changed- files output
9093 elif [[ "${{ github.event_name }}" == "push" ]]; then
91- for file in ${{ steps.changed-files.outputs.all_changed_and_modified_files }}; do
92- if [[ "$file" == ${{ matrix.trigger_path }} ]]; then
93- SHOULD_RUN=true
94- break
95- fi
96- done
94+ if [[ "${{ steps.changed-files.outputs.any_changed }}" == "true" ]]; then
95+ SHOULD_RUN=true
96+ fi
9797 fi
9898 echo "should_run=$SHOULD_RUN" >> $GITHUB_OUTPUT
9999
You can’t perform that action at this time.
0 commit comments