path-based deterministic tagging
This commit is contained in:
6
.github/workflows/build.yml
vendored
6
.github/workflows/build.yml
vendored
@@ -72,7 +72,8 @@ jobs:
|
|||||||
# If workflow changed, rebuild all lanes (use basenames)
|
# If workflow changed, rebuild all lanes (use basenames)
|
||||||
if grep -qx ".github/workflows/build.yml" <<< "$CHANGED"; then
|
if grep -qx ".github/workflows/build.yml" <<< "$CHANGED"; then
|
||||||
echo "Workflow changed; rebuilding all lanes."
|
echo "Workflow changed; rebuilding all lanes."
|
||||||
TARGET_DIRS=("${ALL_NAMES[@]}")
|
# Use full lane paths (e.g. 'docker/7.4') so downstream steps get deterministic dirs
|
||||||
|
TARGET_DIRS=("${ALL_LANES[@]}")
|
||||||
else
|
else
|
||||||
# Build only lanes with changes under their directories
|
# Build only lanes with changes under their directories
|
||||||
TARGET_DIRS=()
|
TARGET_DIRS=()
|
||||||
@@ -81,7 +82,8 @@ jobs:
|
|||||||
lane_name="${ALL_NAMES[$idx]}"
|
lane_name="${ALL_NAMES[$idx]}"
|
||||||
# Any change directly under lane dir counts; include Dockerfile or subpaths
|
# Any change directly under lane dir counts; include Dockerfile or subpaths
|
||||||
if grep -q "^${lane_path}/" <<< "$CHANGED"; then
|
if grep -q "^${lane_path}/" <<< "$CHANGED"; then
|
||||||
TARGET_DIRS+=("${lane_name}")
|
# Append the full lane path (e.g. 'docker/7.4')
|
||||||
|
TARGET_DIRS+=("${lane_path}")
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user