3 JVM=/Library/Java/JavaVirtualMachines
10 SUDO_ASKPASS="${dir}/ask-pass" sudo -A "$0" "$@"
15 osascript -e 'display dialog "Installation failed. Incorrect password?" buttons {"OK"} default button 1 with title "Installation Status"' > /dev/null
23 if ls "$JVM" | grep -q temurin; then
24 echo "Adoptium already present"
26 open https://adoptium.net/
27 osascript -e 'display dialog "Install Java from https://adoptium.net then click Continue" buttons {"Continue"} default button 1 with title "Install Java"' >/dev/null
31 LIBRARY=/Library/AltusMetrum
32 APPLICATIONS=/Applications
35 echo 'Installing' "$file"
38 mkdir -p "${APPLICATIONS}"
39 if [ -d "${APPLICATIONS}/${file}" ]; then
40 rm -rf "${APPLICATIONS}/${file}"
42 cp -a "$file" "${APPLICATIONS}/${file}"
43 chmod -R +w "${APPLICATIONS}/${file}"
44 xattr -rc "${APPLICATIONS}/${file}"
45 APP=`basename "$file" .app`
46 INSTALLED="${INSTALLED} ${APP}"
50 cp -a "$file" "${LIBRARY}"
55 osascript -e 'display dialog "Installation of'"${INSTALLED}"' complete" with title "Installation Complete" buttons {"OK"} default button 1' >/dev/null