Skip to content

Instantly share code, notes, and snippets.

@jonsavage
Last active October 27, 2017 16:10
Show Gist options
  • Save jonsavage/20b858fdd634fb2ca877e0df3ed7abda to your computer and use it in GitHub Desktop.
Save jonsavage/20b858fdd634fb2ca877e0df3ed7abda to your computer and use it in GitHub Desktop.
Install Java Mac Brew
# http://www.lonecpluspluscoder.com/2017/04/27/installing-java-8-jdk-os-x-using-homebrew/
brew cask install java
# Uninstall Non Brew Java
sudo rm -fr /Library/Java/JavaVirtualMachines/jdk-9.jdk/
sudo rm -fr /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin
sudo rm -fr /Library/PreferencePanes/JavaControlPanel.prefPane
#Jenv
http://www.jenv.be/
On OSX all Java versions are located /Library/Java/JavaVirtualMachines/.
jenv add /Library/Java/JavaVirtualMachines/jdk-x-x-x/Contents/Home
jenv add ...
jenv verisons # list all Java Versions Installed
jenv global|shell|local <version> # set version to use
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment