deb
or apt
based distributions like Debian, Ubuntu, Mint and Kali uses apt
package management system. These distributions provides a lot of packages by default. But in some cases we may need to add extra or third party package into our system. This is done with add-apt-repository
. This is not installed by default in these distributions. So we will get following error.
基于deb
或apt
的发行版(如Debian,Ubuntu,Mint和Kali)使用apt
软件包管理系统。 默认情况下,这些发行版提供了很多软件包。 但是在某些情况下,我们可能需要在系统中添加额外的或第三方软件包。 这是通过add-apt-repository
。 这些发行版中默认未安装此软件。 所以我们会得到以下错误。
找不到命令错误 (Command Not Found Error)
So we want to install ubuntu-wine/ppa
which is 3rd party package repository registered as ppa.
因此,我们要安装ubuntu-wine/ppa
,这是注册为ppa的第三方软件包存储库。
$ sudo add-apt-repository ppa:ubuntu-wine/ppa
软件属性通用包装信息(software-properties-common Package Info)
In order to solve `sudo: add-apt-repository: command not found error we need to install the software-properties-common
package. But before installing the package we can list its information with the following command.
为了解决sudo:add-apt-repository:命令未找到错误,我们需要安装software-properties-common
软件包。 但是在安装软件包之前,我们可以使用以下命令列出其信息。
$ apt show software-properties-common
安装software-properties-common软件包(Install software-properties-common Package)
We can install apt-software-common
package with the following command. In this case we need root
privileges in order to install package into our system so we use sudo
.
我们可以使用以下命令安装apt-software-common
软件包。 在这种情况下,我们需要root
特权才能将软件包安装到我们的系统中,因此我们使用sudo
。
$ sudo apt install software-properties-common
翻译自: https://www.poftut.com/solve-add-apt-repository-command-not-found-error-ubuntu-debian-mint-kali/