From 952f483574db38b4f39960a9dbafc1bbb387ab0b Mon Sep 17 00:00:00 2001 From: Jakub Klinkovský Date: Sun, 21 Jan 2024 20:13:03 +0100 Subject: feat(offload-build): fetch logs after building from the remote server MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since logs from offloaded builds are collected in a temporary directory on the remote server, it is rather difficult/error-prone to get to them, because the path changes in each rebuild. Fetching logs from the server into $LOGDEST makes it easier to investigate them and also brings the behavior of offload-build closer to archbuild. Log files are always downloaded, even for failed builds. Component: offload-build Signed-off-by: Jakub Klinkovský Co-authored-by: Levente Polyak --- src/lib/common.sh | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/lib') diff --git a/src/lib/common.sh b/src/lib/common.sh index 7d04c25..641dea5 100644 --- a/src/lib/common.sh +++ b/src/lib/common.sh @@ -354,6 +354,14 @@ is_debug_package() { [[ ${pkgdesc} == "Detached debugging symbols for "* && ${pkgbase}-debug = "${pkgname}" ]] } +# Proxy function to check if a file exists. Using [[ -f ... ]] directly is not +# always wanted because we might want to expand bash globs first. This way we +# can pass unquoted globs to is_globfile() and have them expanded as function +# arguments before being checked. +is_globfile() { + [[ -f $1 ]] +} + join_by() { local IFS="$1" shift -- cgit v1.2.3-70-g09d2