From c21a25f938079f943fab52a209aea3a9546ed487543a741d38348916d954d20c Mon Sep 17 00:00:00 2001 From: "Marc S. Weidner" Date: Tue, 17 Jun 2025 19:02:03 +0200 Subject: [PATCH] V8.03.768.2025.06.17 Signed-off-by: Marc S. Weidner --- lib/lib_check_pkgs.sh | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/lib/lib_check_pkgs.sh b/lib/lib_check_pkgs.sh index 0cabcd4..69658c8 100644 --- a/lib/lib_check_pkgs.sh +++ b/lib/lib_check_pkgs.sh @@ -16,14 +16,13 @@ # None ####################################### check_pkgs() { - if [[ -z "$(command -v lsb_release)" ]]; then - apt-get update -y + apt-get update -y + if [[ -z "$(command -v lsb_release || true)" ]]; then apt-get install --no-install-recommends lsb-release -y fi - if [[ -z "$(command -v debootstrap)" ]]; then + if [[ -z "$(command -v debootstrap || true)" ]]; then if grep -RqsE '^[[:space:]]*deb .*backports' /etc/apt/sources.list /etc/apt/sources.list.d; then - apt-get update -y # shellcheck disable=SC2155 declare codename=$(lsb_release -sc) apt-get -t "${codename}-backports" install debootstrap -y @@ -33,15 +32,17 @@ check_pkgs() { fi if [[ ! -f /usr/share/live/build/VERSION ]]; then - apt-get update -y apt-get install live-build -y fi if [[ -z "$(command -v dialog || true)" ]]; then - if ! $VAR_HANDLER_AUTOBUILD; then apt-get install --no-install-recommends dialog -y; fi + if ! $VAR_HANDLER_AUTOBUILD; then + apt-get install --no-install-recommends dialog -y; + fi fi if [[ -z "$(command -v mkpasswd || true)" ]]; then + apt-get update -y apt-get install --no-install-recommends whois -y fi }