Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add doc to switch between different JDK versions #314

Merged

Conversation

shireeshaBongarala
Copy link
Contributor

@aahlenst
Copy link
Contributor

In my experience, export JAVA_HOME=$(/usr/libexec/java_home -v 13) is sufficient. Alterations of $PATH rather hurt than help on macOS. /usr/bin/java is the default java on macOS and provides the magic that makes JAVA_HOME work. If you prepend the output of export JAVA_HOME=$(/usr/libexec/java_home -v 13) to $PATH, you break all the magic.

@shireeshaBongarala
Copy link
Contributor Author

@aahlenst Thanks for the comment. I fixed the issue in my local $PATH to remove java paths other than /usr/bin/java. Now, just updating the JAVA_HOME env var is sufficient.
I updated the PR.

@mergify mergify bot merged commit c901883 into AdoptOpenJDK:master Feb 25, 2020
@mergify mergify bot added the enhancement New feature or request label Feb 25, 2020
@karianna karianna added this to To do in homebrew-openjdk via automation Mar 6, 2020
@karianna karianna moved this from To do to Done in homebrew-openjdk Mar 6, 2020
@karianna karianna added this to the February 2020 milestone Mar 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants