From 0469d3c902d7b27dd56400e1fb229f47b011c4dc Mon Sep 17 00:00:00 2001 From: Levente Polyak Date: Thu, 8 Feb 2024 21:29:55 +0100 Subject: fix(build): avoid trying to download none existing debug packages Since last release, offload building now has proper error handling enabled. This unfortunately lead to a regression for packages, like any packages, where makepkg claims debug packages are available during --packagelist while none were actually built. This leads to the scp command failing when trying to download the none existing packages which ultimately leads to a termination of the build script. Fix this by filtering out package files that do not exist before trying to download them. Fixes #208 Component: pkgctl build Signed-off-by: Levente Polyak --- src/offload-build.in | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/offload-build.in b/src/offload-build.in index 5238129..0c497b9 100644 --- a/src/offload-build.in +++ b/src/offload-build.in @@ -114,7 +114,9 @@ mapfile -t files < <( if [[ -f /usr/share/devtools/makepkg.conf.d/'"${repo}"'-'"${arch}"'.conf ]]; then makepkg_config="/usr/share/devtools/makepkg.conf.d/'"${repo}"'-'"${arch}"'.conf" fi && - makepkg --config <(cat "${makepkg_user_config}" "${makepkg_config}" 2>/dev/null) --packagelist && + while read -r file; do + [[ -f "${file}" ]] && printf "%s\n" "${file}" ||: + done < <(makepkg --config <(cat "${makepkg_user_config}" "${makepkg_config}" 2>/dev/null) --packagelist) && printf "%s\n" "${temp}/PKGBUILD" ') -- cgit v1.2.3-70-g09d2