diff --git a/modules/ROOT/pages/_partials/proc_installing-openjdk.adoc b/modules/ROOT/pages/_partials/proc_installing-openjdk.adoc index 7439275..e892b11 100644 --- a/modules/ROOT/pages/_partials/proc_installing-openjdk.adoc +++ b/modules/ROOT/pages/_partials/proc_installing-openjdk.adoc @@ -4,38 +4,24 @@ To install OpenJDK from the Fedora repository: . Run the following command to list available versions: -+ + ---- $ dnf search openjdk ---- + . Copy the version of OpenJDK you want to install. -+ + [NOTE] -==== Various flavors of OpenJDK are available. For information about these options, search the link:http://openjdk.java.net/[OpenJDK web site]. -==== -+ -. Run the following command to install OpenJDK: -+ + +* Run the following command to install OpenJDK: + ---- # dnf install ---- -+ + For example: -+ ----- -# dnf install java-1.8.0-openjdk.x86_64 ----- - -// tag::java-alternatives[] -[NOTE] -==== -If you have installed other versions of Java, you might need to switch the active version of Java: ---- -# alternatives --config java +# dnf install java-{1.8.0|11|latest}-openjdk.x86_64 ---- - -A list of installed Java versions is displayed. Choose the version you require. -==== -// end::java-alternatives[] diff --git a/modules/ROOT/pages/_partials/proc_installing-oracle-java.adoc b/modules/ROOT/pages/_partials/proc_installing-oracle-java.adoc index 803d42b..cb4c87e 100644 --- a/modules/ROOT/pages/_partials/proc_installing-oracle-java.adoc +++ b/modules/ROOT/pages/_partials/proc_installing-oracle-java.adoc @@ -1,18 +1,37 @@ [id='installing-oracle-java-se'] = Installing Oracle Java SE +include::{partialsdir}/3rdparty-message.adoc[] + To install Oracle Java SE: -. Navigate to link:http://www.oracle.com/technetwork/java/javase/downloads[Oracle Java SE downloads page]. - -. Choose the version of Java you wish to use. Typically, you would navigate to the link:http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html[version 8 page]. +. Navigate to link:http://www.oracle.com/technetwork/java/javase/downloads[Oracle Java SE downloads page], and + choose the version of Java you wish to use. . Accept the license agreement and download the appropriate tar.gz file for your systems architecture. Do NOT use Oracle rpms as these are NOT compatible with fedora/openjdk packages. Download tar.gz instead and unpack it somewhere. -. Use tar to unpack downloaded archive e.g.: -+ +. Use `DNF` to install it the downloaded version e.g.: + ---- -# tar -xvzf jdk-8u201-linux-x64.tar.gz +sudo dnf install version-downloaded.rpm ---- -Note that jdk-8u201-linux-x64.tar.gz is used as example only. Always make sure to download latest version available. +Note: Always make sure to download latest version available. + +== Switching between Java Versions + +You might have installed several versions of Java on your system, you can switch from one + +After running this command, you will see a a list of all installed Java versions, select t + +---- +sudo alternatives --config java +---- + +Simply enter a selection number to choose which java executable should be used by default. + +* verify: + +---- +java --Versions +---- diff --git a/modules/ROOT/pages/installing-java.adoc b/modules/ROOT/pages/installing-java.adoc index f1c59f1..a39bb5b 100644 --- a/modules/ROOT/pages/installing-java.adoc +++ b/modules/ROOT/pages/installing-java.adoc @@ -17,6 +17,14 @@ Most Java applications run on one of the following: * Oracle Java SE -- a free JDK from Oracle. This version is not open-source and we recommend that it only be used if OpenJDK is not sufficient. +You can find the following Versions: + +* Version (Ex. 8) + +* Long Term Support or `LTS` + +* Latest + include::{partialsdir}/proc_installing-openjdk.adoc[leveloffset=+1] include::{partialsdir}/proc_installing-oracle-java.adoc[leveloffset=+1] @@ -31,7 +39,7 @@ For Java in Fedora, see: * link:https://admin.fedoraproject.org/mailman/listinfo/java-devel[java-devel mailing list] * Freenode IRC channel link:irc://irc.freenode.net/fedora-java[#fedora-java] -* link:https://Ask.FedoraProject.org/en/questions/scope:all/sort:activity-desc/tags:java/page:1/[Ask Fedora about Java] +* link:https://ask.fedoraproject.org/tags/java[Ask Fedora about Java] For more information about Java in general, see: