Overhaul checkdiff CI (#1930)

This commit is contained in:
Eldred Habert
2026-04-12 22:06:28 +02:00
committed by GitHub
parent 0e6e91d048
commit 017b0119e6
2 changed files with 17 additions and 13 deletions
+4 -4
View File
@@ -3,17 +3,17 @@
# SPDX-License-Identifier: MIT
declare -A FILES
while read -r -d '' file; do
FILES["$file"]="true"
while IFS= read -r -d '' file; do
FILES["$file"]=true
done < <(git diff --name-only -z "$1" HEAD)
edited () {
${FILES["$1"]:-"false"}
${FILES["$1"]:-false}
}
dependency () {
if edited "$1" && ! edited "$2"; then
echo "'$1' was modified, but not '$2'! $3" | xargs
echo "'$1' was modified, but not '$2'! $3"
fi
}