Created
June 25, 2015 23:11
-
-
Save robobenklein/84817be7cc3f5e1c9a5d to your computer and use it in GitHub Desktop.
Easily Switch between Webupd8's Java 7 and Java 8 by shell script.
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
read -p "Which java version should we switch to? 7 or 8? : " action | |
case $action in | |
7 ) sudo update-java-alternatives -s java-7-oracle && echo "Switched to Java 7";; | |
8 ) sudo update-java-alternatives -s java-8-oracle && echo "Switched to Java 8";; | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment