I am unable to add a repository via the command line on Ubuntu 14.04. Apt-get works perfectly fine, and I am able to update the system. I have configured my /etc/apt/apt.config file as follows:
Acquire::http::proxy "http://<username>:<password>@<proxy address>:<port>/";
For example, when trying to add the repository for y-ppa-manager, I receive:
add-apt-repository ppa:webupd8team/y-ppa-manager Cannot add PPA: 'ppa:webupd8team/y-ppa-manager'. Please check that the PPA name or format is correct.
If you need any more info., feel free to ask.
Here is Solutions:
We have many solutions to this problem, But we recommend you to use the first solution because it is tested & true solution that will 100% work for you.
You need to export your proxy environment variables using
export http_proxy=http://username:[email protected]:port/ export https_proxy=https://username:[email protected]:port/
and then tell sudo to use them using:
sudo -E add-apt-repository ppa:webupd8team/y-ppa-manager
or open your
/etc/sudoers file (using
sudo visudo) and append
to the end of the file.
I have a blog on this, have a look at it for more details.
Note: Use and implement solution 1 because this method fully tested our system.
Thank you 🙂