From ed6492621b121d72265d4f7e4e7b62bc84c276b1 Mon Sep 17 00:00:00 2001 From: Igor Pecovnik Date: Sun, 9 Feb 2025 21:08:38 +0100 Subject: [PATCH] Bugfix: Remove directories from sha files --- lib/functions/image/compress-checksum.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/functions/image/compress-checksum.sh b/lib/functions/image/compress-checksum.sh index f103d960be74..824092e2b254 100644 --- a/lib/functions/image/compress-checksum.sh +++ b/lib/functions/image/compress-checksum.sh @@ -45,7 +45,8 @@ function output_images_compress_and_checksum() { if [[ $COMPRESS_OUTPUTIMAGE == *sha* ]]; then display_alert "SHA256 calculating" "${uncompressed_file_basename}${compression_type}" "info" - sha256sum -b "${uncompressed_file}${compression_type}" > "${uncompressed_file}${compression_type}".sha + # awk manipulation is needed to get rid of temporal folder path from SHA signature + sha256sum -b "${uncompressed_file}${compression_type}" | awk '{split($2, a, "/"); print $1, a[length(a)]}' > "${uncompressed_file}${compression_type}".sha fi done