Skip to content

Commit ccce2b6

Browse files
committed
The key changes are:
Modified the logic to use two conditions: First check if there ARE configure/Makefile files (grep -qE) Then check if there are NO other files (! grep -qvE) Only skip Windows CI when BOTH conditions are true (only configure-related files changed) This way, Windows CI will be skipped only when ALL changed files are configure/Makefile related, and will run if there are any other changes
1 parent c904238 commit ccce2b6

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

.github/workflows/reusable-change-detection.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -124,13 +124,14 @@ jobs:
124124
# Get changed files
125125
CHANGED_FILES=$(git diff --name-only "origin/$GITHUB_BASE_REF..")
126126
127-
# Check if changes are only in configure/Makefile files
128-
if echo "$CHANGED_FILES" | grep -qvE '^(configure.*|Makefile.*|.*\.m4)$'; then
129-
# Other files changed, run Windows CI
130-
echo "run-windows=true" >> "$GITHUB_OUTPUT"
131-
else
127+
# Check if changes are ONLY in configure/Makefile files
128+
if echo "$CHANGED_FILES" | grep -qE '^(configure.*|Makefile.*|.*\.m4)$' && \
129+
! echo "$CHANGED_FILES" | grep -qvE '^(configure.*|Makefile.*|.*\.m4)$'; then
132130
# Only configure/Makefile files changed, skip Windows CI
133131
echo "run-windows=false" >> "$GITHUB_OUTPUT"
132+
else
133+
# Other files changed, run Windows CI
134+
echo "run-windows=true" >> "$GITHUB_OUTPUT"
134135
fi
135136
fi
136137
- name: Compute hash for config cache key

0 commit comments

Comments
 (0)