diff options
author | Leah Rowe <leah@libreboot.org> | 2025-05-04 08:29:19 +0100 |
---|---|---|
committer | Leah Rowe <leah@libreboot.org> | 2025-05-05 12:18:22 +0100 |
commit | 3c0bef558de63086aa5ec9fb90eda5bd7cb9296a (patch) | |
tree | 6ad2bcb45fa1ff0bedd54e713ca8baac0b21c399 | |
parent | 674fc35011f47a32dd5bcd478389a4949c7deea6 (diff) |
init.sh: simplify dependencies handling
Signed-off-by: Leah Rowe <leah@libreboot.org>
-rw-r--r-- | include/init.sh | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/include/init.sh b/include/init.sh index 7026594a..fc321605 100644 --- a/include/init.sh +++ b/include/init.sh @@ -26,10 +26,7 @@ xbmk_init() export PWD="$xbmkpwd" - if [ $# -gt 0 ] && [ "$1" = "dependencies" ]; then - install_packages "$@" || exit 1 - exit 0 - fi + [ $# -gt 0 ] && [ "$1" = "dependencies" ] && x_ xbmkpkg "$@" && exit 0 id -u 1>/dev/null 2>/dev/null || $err "suid check failed (id -u)" [ "$(id -u)" != "0" ] || $err "this command as root is not permitted" @@ -40,7 +37,7 @@ xbmk_init() done } -install_packages() +xbmkpkg() { [ $# -lt 2 ] && $err "fewer than two arguments" [ $# -gt 2 ] && reinstall="$3" |