Merge pull request #291 from MaxMustermann2/linux-path-fix

script: fix `linux` download path
dependabot/go_modules/github.com/valyala/fasthttp-1.34.0
Soph 2 years ago committed by GitHub
commit 1c24234c95
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 15
      scripts/hmy.sh

@ -20,12 +20,15 @@ set_download () {
local rel='mainnet' local rel='mainnet'
case "$OS" in case "$OS" in
Darwin) Darwin)
FOLDER=release/darwin-x86_64/${rel}/ FOLDER=release/darwin-x86_64/${rel}
URL=http://${BUCKET}.s3.amazonaws.com/${FOLDER}
BIN=( hmy libbls384_256.dylib libcrypto.1.0.0.dylib libgmp.10.dylib libgmpxx.4.dylib libmcl.dylib ) BIN=( hmy libbls384_256.dylib libcrypto.1.0.0.dylib libgmp.10.dylib libgmpxx.4.dylib libmcl.dylib )
NAMES=("${BIN[@]}")
;; ;;
Linux) Linux)
FOLDER=release/linux-x86_64/${rel}/ URL=https://harmony.one
BIN=( hmy ) BIN=( hmycli )
NAMES=( hmy )
;; ;;
*) *)
echo "${OS} not supported." echo "${OS} not supported."
@ -36,9 +39,9 @@ set_download () {
do_download () { do_download () {
# download all the binaries # download all the binaries
for bin in "${BIN[@]}"; do for i in "${!BIN[@]}"; do
rm -f ${bin} rm -f ${NAMES[i]}
curl http://${BUCKET}.s3.amazonaws.com/${FOLDER}${bin} -o ${bin} curl -L ${URL}/${BIN[i]} -o ${NAMES[i]}
done done
chmod +x hmy chmod +x hmy
} }

Loading…
Cancel
Save