summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2025-10-04 03:05:23 +0100
committerLeah Rowe <leah@libreboot.org>2025-10-04 03:05:23 +0100
commit0a74cc8ec6038492f64074e18cc10ba7ab31ac94 (patch)
tree9e36fbc0d874c8e0aa25aab32799830d88bdac3b /include
parenta09ec1d02b275fa0d79a0a21be77d450fd86318b (diff)
xbmk: clean up a few err calls
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'include')
-rw-r--r--include/init.sh8
-rw-r--r--include/tree.sh3
2 files changed, 6 insertions, 5 deletions
diff --git a/include/init.sh b/include/init.sh
index 2db869ea..31d2b533 100644
--- a/include/init.sh
+++ b/include/init.sh
@@ -382,9 +382,11 @@ pybin()
xbmk_git_init()
{
for gitarg in "--global user.name" "--global user.email"; do
- gitcmd="git config $gitarg"; $gitcmd 1>/dev/null 2>/dev/null \
- || err "Run this first: $gitcmd \"your ${gitcmd##*.}\"" \
- "xbmk_git_init" "$@"
+ gitcmd="git config $gitarg"
+ if ! $gitcmd 1>/dev/null 2>/dev/null; then
+ err "Run this first: $gitcmd \"your ${gitcmd##*.}\"" \
+ "xbmk_git_init" "$@"
+ fi
done
if [ -L ".git" ]; then
diff --git a/include/tree.sh b/include/tree.sh
index 229c6508..98442e5c 100644
--- a/include/tree.sh
+++ b/include/tree.sh
@@ -372,8 +372,7 @@ project_up_to_date()
x_ mkdir -p "$XBMK_CACHE/$hashdir"
if [ -f "$XBMK_CACHE/$hashdir/$project$hashname" ]; then
- read -r old_hash < \
- "$XBMK_CACHE/$hashdir/$project$hashname" \
+ read -r old_hash < "$XBMK_CACHE/$hashdir/$project$hashname" \
|| err \
"$hashdir: err '$XBMK_CACHE/$hashdir/$project$hashname'" \
"project_up_to_date" "$hashdir" "$hashname" "$badhashvar" \