Linux Shell Scripts

#!/bin/bash url=$1 && file=”${url##*/}” && wget $url && extension=”${url##*.}” && echo -e “\n\n” if [ $extension = ‘js’ ] then echo -e “Generate JS HTML output\n” echo -ne “\n\n” elif [ $extension = ‘css’ ] then echo -e “Generate CSS HTML output\n” echo -ne “\n\n” elif [ $extension = ‘webp’ | $extension = ‘png’ | Read More …

Install Java 8 or Java 9 on Debian

add the oracle ppa echo “deb https://ppa.launchpad.net/webupd8team/java/ubuntu xenial main” | tee /etc/apt/sources.list.d/webupd8team-java.list echo “deb-src https://ppa.launchpad.net/webupd8team/java/ubuntu xenial main” | tee -a /etc/apt/sources.list.d/webupd8team-java.list apt-key adv –keyserver hkp://keyserver.ubuntu.com:80 –recv-keys EEA14886 apt-get update Java 8 echo oracle-java8-installer shared/accepted-oracle-licence-v1-1 boolean true | sudo /usr/bin/debconf-set-selections apt-get install oracle-java8-installer sudo apt-get install oracle-java8-set-default Java 9 echo oracle-java9-installer shared/accepted-oracle-license-v1-1 select true | sudo /usr/bin/debconf-set-selections Read More …