From 5aba26cf7ddf6e5ba97052d48436ad07bf8a50f1 Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Tue, 19 Aug 2025 20:15:26 +0200 Subject: [PATCH] Fix. --- trixie/scripts/lib/apt_digested.sh | 8 ++++---- trixie/scripts/setup_desktop.sh | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/trixie/scripts/lib/apt_digested.sh b/trixie/scripts/lib/apt_digested.sh index a6abe64..4288aac 100644 --- a/trixie/scripts/lib/apt_digested.sh +++ b/trixie/scripts/lib/apt_digested.sh @@ -140,7 +140,7 @@ apt_digested() { local FIRST_FIELD FIRST_FIELD=$(echo "${APT_LINE}" | cut -d' ' -f1) if [ "${FIRST_FIELD}" = "${FINISH_LINE}" ]; then - printf '%s' "${OUR_NEWLINE}" + echo -n "${OUR_NEWLINE}" local EXIT_CODE EXIT_CODE=$(echo "${APT_LINE}" | cut -d' ' -f2) if [ "${EXIT_CODE}" != "0" ]; then @@ -159,7 +159,7 @@ apt_digested() { local IFS IFS=$(printf '\n\r') for LINE in ${apt_digested_SEDS}; do - I=$((1 + "$I")) + I=$((1 + $I)) if [ "$I" -eq 1 ]; then PREFIX="${LINE}" continue @@ -187,12 +187,12 @@ apt_digested() { if [ "${COMPRESSED_ITEM}" = 'IGNORE' ]; then continue elif [ -z "${COMPRESSED_ITEM}" ]; then - printf '%s' "${OUR_NEWLINE}" + echo -n "${OUR_NEWLINE}" prefixed_msg_no_nl "${APT_LINE}" LAST_PREFIX= else if [ "${PREFIX}" != "${LAST_PREFIX}" ]; then - printf '%s' "${OUR_NEWLINE}" + echo -n "${OUR_NEWLINE}" prefixed_msg_no_nl "# ${PREFIX}" LAST_PREFIX="${PREFIX}" fi diff --git a/trixie/scripts/setup_desktop.sh b/trixie/scripts/setup_desktop.sh index a74343e..d771382 100755 --- a/trixie/scripts/setup_desktop.sh +++ b/trixie/scripts/setup_desktop.sh @@ -1,5 +1,5 @@ #!/usr/bin/env dash -set -eu +set -e ROOT=$(dirname "$0") cd "${ROOT}" . lib/abort.sh @@ -64,7 +64,7 @@ adopt_wifi_connection() { } # NB: This needs to come before steps potentially overwriting /etc/network/interfaces. -apt_digested '-q -q install network-manager' +apt_digested -q -q install network-manager if [ "$(nmcli -f TYPE conn | grep -c 'wifi')" = "0" ]; then prefixed_msg "Checking for existing wifi config in ${PATH_NETWORK_INTERFACES} …" adopt_wifi_connection -- 2.30.2