Search notes:

add-apt-repository

add-apt-repository is a Python script that adds or removes an (external) APT repository from /etc/apt/sources.list or /etc/apt/sources.list.d/.
apt-add-repository is a symlink to add-apt-repository.

Examples

apt-add-repository 'deb http://myserver/path/to/repo stable myrepo'
apt-add-repository 'http://myserver/path/to/repo myrepo'
apt-add-repository 'https://packages.medibuntu.org free non-free'
apt-add-repository http://extras.ubuntu.com/ubuntu
apt-add-repository ppa:user/repository
apt-add-repository ppa:user/distro/repository
apt-add-repository multiverse

add-apt-repository: command not found

Error message thrown:
$ sudo add-apt-repository ppa:git-core/ppa -y
sudo: add-apt-repository: command not found
Try to fix it:
$ sudo apt install -y software-properties-common
C'mon…
$ sudo add-apt-repository ppa:git-core/ppa -y
  …
FileNotFoundError: [Errno 2] No such file or directory: 'gpg': 'gpg'
Try again
$ sudo apt-get install gpg
Finally:
$ sudo add-apt-repository ppa:git-core/ppa -y

See also

apt-add-repository

Index