feat: release windows binaries as zip

This commit is contained in:
Ivan Dyachkov 2023-02-15 10:39:49 +01:00
parent 67f88f27fd
commit fb244464d7
1 changed files with 10 additions and 0 deletions

10
build
View File

@ -233,6 +233,9 @@ make_tgz() {
macos*)
target_name="${PROFILE}-${full_vsn}.zip"
;;
windows*)
target_name="${PROFILE}-${full_vsn}.zip"
;;
*)
target_name="${PROFILE}-${full_vsn}.tar.gz"
;;
@ -298,6 +301,13 @@ make_tgz() {
# sha256sum may not be available on macos
openssl dgst -sha256 "${target}" | cut -d ' ' -f 2 > "${target}.sha256"
;;
windows*)
pushd "${tard}" >/dev/null
7z a "${target_name}" ./emqx/* >/dev/null
popd >/dev/null
mv "${tard}/${target_name}" "${target}"
sha256sum "${target}" | head -c 64 > "${target}.sha256"
;;
*)
## create tar after change dir
## to avoid creating an extra level of 'emqx' dir in the .tar.gz file