xbmk: simplify a few err calls

many of the messages are redundant, because errors caused
by the commands they handle would produce similar messages.

Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
Leah Rowe
2025-05-27 11:57:13 +01:00
parent dbf0fda39a
commit aacd46bf81
4 changed files with 5 additions and 10 deletions
+2 -4
View File
@@ -45,8 +45,7 @@ trees()
[ -z "$_f" ] && err "missing flag ($flags)"
[ -z "$project" ] && fx_ "x_ ./mk $_f" x_ ls -1 config/git && return 1
[ -f "config/git/$project/pkg.cfg" ] || \
err "config/git/$project/pkg.cfg missing"
e "config/git/$project/pkg.cfg" f missing && err "$project: no pkg.cfg"
for d in "elf" "config/data" "config" "src"; do
eval "${d#*/}dir=\"$d/$project\""
@@ -187,8 +186,7 @@ check_project_hashes()
[ "$pjhash" != "$old_pjhash" ] && badhash="y"
[ -f "$XBMK_CACHE/hash/$project$tree" ] || badhash="y"
printf "%s\n" "$pjhash" > "$XBMK_CACHE/hash/$project$tree" || \
err "!mk $XBMK_CACHE/hash/$project$tree"
printf "%s\n" "$pjhash" > "$XBMK_CACHE/hash/$project$tree" || err
[ "$badhash" != "y" ] || x_ rm -Rf "src/$project/$tree" \
"elf/$project/$tree" "elf/$project/$target"; :