summaryrefslogtreecommitdiff
path: root/include/tree.sh
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2025-05-27 11:57:13 +0100
committerLeah Rowe <leah@libreboot.org>2025-05-27 11:57:13 +0100
commitaacd46bf812369710a0080b7e51f1a1c7d1ce9ee (patch)
treee4a05c126b812dc782e29a3684fcea988808692b /include/tree.sh
parentdbf0fda39a78504e76d24e907db130b542cb286a (diff)
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>
Diffstat (limited to 'include/tree.sh')
-rw-r--r--include/tree.sh6
1 files changed, 2 insertions, 4 deletions
diff --git a/include/tree.sh b/include/tree.sh
index 11607eed..e8f55c48 100644
--- a/include/tree.sh
+++ b/include/tree.sh
@@ -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"; :