From 8b9b814f52ab4ce0974e0705280e28780b8a14ad Mon Sep 17 00:00:00 2001 From: Eric Chiang Date: Wed, 19 Jan 2022 09:31:42 -0800 Subject: [PATCH] scripts: don't include '.' in the release TAR file Also print the contents of the file after building to help debugging. --- scripts/build-release.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/build-release.sh b/scripts/build-release.sh index 33ed77c..ab2c27f 100755 --- a/scripts/build-release.sh +++ b/scripts/build-release.sh @@ -56,13 +56,16 @@ function build { zip -r "$TARGET" ./ cd - else + TARGET="${PWD}/bin/log4jscanner-${VERSION}-${GOOS}-${GOARCH}.tar.gz" tar \ --group=root \ --owner=root \ -czvf \ - "${PWD}/bin/log4jscanner-${VERSION}-${GOOS}-${GOARCH}.tar.gz" \ + "$TARGET" \ -C "$TEMP_DIR" \ - "./" + "./log4jscanner" + # Print the contents of the TAR so we can visually debug it during CI. + tar -ztvf "$TARGET" fi rm -rf "$TEMP_DIR" }