-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[java] Switch java installation from jenv -> asdf
- Loading branch information
1 parent
007aac5
commit ebcf5e5
Showing
2 changed files
with
18 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,24 @@ | ||
#!/bin/sh | ||
|
||
if test ! $(which jenv) | ||
# See available versions: asdf list-all java | ||
export JAVA_VER="openjdk-11.0.1" | ||
|
||
if test ! $(which asdf) | ||
then | ||
echo " Installing jenv for you." | ||
brew install jenv > /tmp/jenv-install.log | ||
echo " asdf is required.." | ||
$ZSH/asdf/install.sh | ||
fi | ||
|
||
# https://github.com/skotchpine/asdf-java | ||
asdf plugin-add java | ||
asdf plugin-update java | ||
|
||
echo "Installing java.." | ||
brew cask install java > /tmp/java-install.log | ||
asdf install java $JAVA_VER | ||
asdf global java $JAVA_VER | ||
|
||
echo "Java versions installed:" | ||
asdf list java | ||
|
||
echo "Current Java version in use:" | ||
asdf current java |
This file was deleted.
Oops, something went wrong.