Ben Chuanlong Du's Blog

It is never too late to learn.

Java PPA for Ubuntu

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

sudo add-apt-repository ppa:webupd8team/java

If you are behind a firewall and has to communicate to the internal via a proxy, you can first export the environment vairables http_proxy and https_proxy.

export http_proxy='proxy_server:port'
export https_proxy='proxy_server:port'

If a user name and password is needed, export them using the following command.

export http_proxy=http://username:password@proxy_server:port
export https_proxy=https://username:password@proxy_server:port

However, make sure to run sudo with the -E (preserve environment) option.

sudo -E add-apt-repository ppa:webupd8team/java

Comments