From 68d8f10666f894f6af8af5800d2d91aadec6d7d5 Mon Sep 17 00:00:00 2001 From: Ricardo Pardini Date: Thu, 12 Jan 2023 15:50:37 +0100 Subject: [PATCH] armbian-oleg: make `chroot_sdcard_apt_get_install_dry_run()` logging more useful by filtering the noise out --- lib/functions/logging/runners.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/functions/logging/runners.sh b/lib/functions/logging/runners.sh index 91bad2654..d0d6fe5ab 100644 --- a/lib/functions/logging/runners.sh +++ b/lib/functions/logging/runners.sh @@ -13,7 +13,11 @@ function chroot_sdcard_apt_get_install_download_only() { } function chroot_sdcard_apt_get_install_dry_run() { - chroot_sdcard_apt_get --no-install-recommends --dry-run install "$@" + local logging_filter="" + if [[ "${SHOW_DEBUG}" != "yes" ]]; then + logging_filter="2>&1 | { grep --line-buffered -v -e '^Conf ' -e '^Inst ' || true; }" + fi + chroot_sdcard_apt_get --no-install-recommends --dry-run install "$@" "${logging_filter}" } function chroot_sdcard_apt_get_remove() {