From 0ba817733f0aa7d54473209b99f0fd90176d3a52 Mon Sep 17 00:00:00 2001 From: Evan Niessen-Derry Date: Mon, 18 Sep 2023 13:22:30 -0500 Subject: [PATCH] Move ASDF plugin installation into Cloudflare ENV vars We have to use the `UNSTABLE_PRE_BUILD` env var in our build process to get the asdf `java` plugin installed before the build system installs the tool versions defined in our `.tool-versions` file. I'm wary of using an ENV var labeled "UNSTABLE", as it might disappear without warning, but also this project has effectively no risk, so I'm going to go with the ease of use it affords us. --- build.sh | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/build.sh b/build.sh index 57f7340..aaf75d0 100644 --- a/build.sh +++ b/build.sh @@ -1,23 +1,14 @@ #!/bin/bash -echo "Inspecting asdf plugins" -asdf info -asdf plugin list - echo "Beginning build" +# This will auto-succeed in the CI environment, but I've kept it here in case others come to use the +# script echo "installing asdf java plugin" asdf plugin add java https://github.com/halcyon/asdf-java.git echo "Installing local versions" asdf install -# echo "Fetching JDK" -# # Grab the java binary and put it in our path -# wget https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.8%2B7/OpenJDK17U-jre_x64_linux_hotspot_17.0.8_7.tar.gz -# # When transform the initial directory name into something static, to make it easier to work with -# tar --gzip --transform 's,^[^/]+,jdk,x' --extract --file OpenJDK17U-jre_x64_linux_hotspot_17.0.8_7.tar.gz -# export PATH=$PWD/jdk/bin:$PATH - echo "Building release" npx shadow-cljs release :client