A Bash Shell script that will install Oracle JDK, after you download it from oracle.com
A Bash Shell script that will install Oracle® Java SE JDK (see notes below),
after you download it from
oracle.com.
LINUX // Debian-based distributions
(Developed on Linux Mint 18)
GNU GENERAL PUBLIC LICENSE Version 2, June 1991
There are two ways that you can execute this script.
1st way:
sudo ./installOracleJDK.sh
In order to use this way, you have to download the ‘.tar.gz‘ file of
your choice from oracle.com and save it inside the Downloads directory of
your account. After download is complete, run the above command. During execution
you will be asked to enter your username (username@host), in order for the
script to enter /home/username/Downloads/ and search for the file to be installed.
2nd way:
sudo ./installOracleJDK.sh [absolute-path-of-directory]
This way allows you to provide the absolute path of the directory containing
the ‘.tar.gz‘ file as a command line argument, in order to override the default
option.
Command example:
sudo ./installEOracleJDK /home/gzachos/Desktop/
In case more than one ‘.tar.gz‘ files exist inside the specified directory,
you will be prompted just like it is shown in the screenshot below, to choose
the one you want to be installed.
e.g.