@@ -54,11 +54,13 @@ prerequisites() {
5454}
5555
5656clean_cache () {
57+ log " Cleaning cache bin/ directory"
5758 rm -rf bin/*
5859}
5960
6061build_cli_cross_platform () {
6162 clean_cache
63+ log " Building cross-platform binaries"
6264 make build-cli-cross-platform
6365}
6466
@@ -68,7 +70,7 @@ generate_shasums() {
6870 log " Generating sha256sum Hashes"
6971 for target in ${TARGETS[*]} ; do
7072
71- if [[ " $target " =~ / linux/ ]]; then
73+ if [[ " $target " =~ linux ]]; then
7274 _compressed=" $target .tar.gz"
7375 else
7476 _compressed=" $target .zip"
@@ -86,11 +88,16 @@ generate_shasums() {
8688# need the raw binaries anymore.
8789compress_targets () {
8890 log " Compressing target binaries"
91+ local _target_with_ext
8992 for target in ${TARGETS[*]} ; do
90- if [[ " $target " =~ /linux/ ]]; then
91- tar -czvf " bin/${target} .tar.gz" " bin/${target} "
93+ if [[ " $target " =~ linux ]]; then
94+ _target_with_ext=" bin/${target} .tar.gz"
95+ log $_target_with_ext
96+ tar -czvf " ${_target_with_ext} " " bin/${target} " 2> /dev/null
9297 else
93- zip " bin/${target} .zip" " bin/${target} "
98+ _target_with_ext=" bin/${target} .zip"
99+ log $_target_with_ext
100+ zip " ${_target_with_ext} " " bin/${target} " > /dev/null
94101 fi
95102 rm -f " bin/${target} "
96103 done
0 commit comments