Skip to content

Instantly share code, notes, and snippets.

@zhangzhiqiangcs
Last active August 8, 2017 08:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zhangzhiqiangcs/9852aca52a83ea4b4b8818c093b297a6 to your computer and use it in GitHub Desktop.
Save zhangzhiqiangcs/9852aca52a83ea4b4b8818c093b297a6 to your computer and use it in GitHub Desktop.
JDK版本从1.7升级到1.8
# Ubuntu
# add-apt-repository: command not found
# 查看Ubuntu版本
cat /etc/issue
# For Ubuntu 14.04 or 16.04 you need another package:
apt-get install software-properties-common
# If you are using an older release of Ubuntu, ie before 12.10, it is necessary to install the package python-software-properties
sudo apt-get install python-software-properties
add-apt-repository ppa:webupd8team/java
apt-get update
apt-get install oracle-java8-installer
# 切换到jdk8
sudo update-java-alternatives -s java-8-oracle
# 完成
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment