Categories

  • articles

Tags

  • java

Java 8 JDK final got released today so time install!

Add the PPA:

sudo add-apt-repository ppa:webupd8team/java

Update and install

sudo apt-get update
sudo apt-get install oracle-java8-installer

Using the correct version? If you have java-7-orcale, java-7-openjdk, etc installed on your machine you now need to make sure the default is set to java-8-oracle. This will list all the installed options for Java:

sudo update-alternatives --list java

This will let you chose the default version of Java to use:

sudo update-alternatives --config java

That is it lambda time!

UPDATE:

There is a much better way to change the default java version. This will change the compiler (javac) and other executables also to be Java 8.

sudo update-java-alternatives -s java-8-oracle