md5sum fix lint restore cache use file use caching fix config config fix grep fix lint nightly catch webpack url curl check curl use plus install jq use npx do not use jq rename cache filter duplicates manual versions fix manual v3 8.18 fix urls 7.6 fix regex fix latest remixd renamepull/3668/head
parent
78e0bc7631
commit
049a10353f
@ -0,0 +1,32 @@ |
||||
#!/usr/bin/env bash |
||||
|
||||
set -e |
||||
# check if curl is installed |
||||
if ! command -v curl &> /dev/null |
||||
then |
||||
echo "curl could not be found" |
||||
exit |
||||
fi |
||||
|
||||
|
||||
# download https://binaries.soliditylang.org/wasm/list.json as json |
||||
curl https://binaries.soliditylang.org/wasm/list.json > list.json |
||||
# get the latest version without jq |
||||
latest=$(grep 'latestRelease' list.json | cut -d '"' -f 4) |
||||
echo "latest version: $latest" |
||||
# get url |
||||
url=$(grep "\"$latest\":" list.json | cut -d '"' -f 4) |
||||
echo "url: $url" |
||||
path="https://binaries.soliditylang.org/bin/$url" |
||||
echo "path: $path" |
||||
# download the file to ./apps/remix-ide/src/assets/js/soljson.js |
||||
curl $path > ./apps/remix-ide/src/assets/js/soljson.js |
||||
# if directory ./apps/remix-ide/src/assets/js/soljson does not exist, create it |
||||
if [ ! -d "./apps/remix-ide/src/assets/js/soljson" ]; then |
||||
mkdir ./apps/remix-ide/src/assets/js/soljson |
||||
fi |
||||
cp ./apps/remix-ide/src/assets/js/soljson.js ./apps/remix-ide/src/assets/js/soljson/$url |
||||
|
||||
# remove list.json |
||||
rm list.json |
||||
|
Loading…
Reference in new issue