-
-
Save giabao/8414868 to your computer and use it in GitHub Desktop.
Use aria2c to download file1. add params (to speedup downloading): -s16 -x16 -k1M2. add --check-certificate=false3. simulate -o option of curl: dl -o /dir/file url will download file to /dir/file insteads of ./dir/file_______Install:1. apt-get install aria2c2. Download & chmod a+x /usr/bin/dl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias dl='aria2c -x16 -s16 -k1M' | |
cd ~/Downloads/ | |
dl --header="Cookie: oraclelicense=a" http://download.oracle.com/otn-pub/java/jdk/8u91-b14/jdk-8u91-linux-x64.tar.gz | |
sudo mkdir -p /opt/java && cd /opt/java | |
sudo mv ~/Downloads/jdk-8u91-linux-x64.tar.gz . | |
sudo tar -xzf jdk-8u91-linux-x64.tar.gz | |
sudo ln -sfT jdk1.8.0_91 default | |
sudo rm -f jdk-8u91-linux-x64.tar.gz | |
update-alternatives --display java | |
sudo update-alternatives --install /usr/bin/java java /opt/java/default/bin/java 1 | |
java -version | |
sudo update-alternatives --install /usr/bin/javac javac /opt/java/default/bin/javac 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment