无法在Linux Mint 17.3上安装git

时间:2017-05-04 18:23:49

标签: linux git install packages

我正在尝试安装git几个小时,但无论我做什么,我都会收到此错误:

 sudo apt-get install git
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 git : Depends: liberror-perl but it is not installable
E: Unable to correct problems, you have held broken packages.

我在这里阅读了答案,我尝试了以下内容但没有成功: sudo apt-get update
sudo apt-get upgrade sudo apt-get install -f

我从这里尝试过解决方案:

https://superuser.com/questions/899311/apt-get-error-when-installing-git

我删除了/var/lib/apt/lists/*中的所有内容并运行了sudo apt-get update 我还尝试安装liberror-perl,然后安装以下错误:

Reading package lists... Done Building dependency tree
Reading state information... Done Package liberror-perl is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package 'liberror-perl' has no installation candidate

如何解决这个问题呢?感谢。

更新:现在我尝试安装另一个软件包,我得到了同样的错误:

Package 'devscripts' has no installation candidate

1 个答案:

答案 0 :(得分:-1)

您是否尝试过按此链接中的说明操作? https://tecadmin.net/install-git-on-ubuntu/

$ sudo add-apt-repository ppa:git-core/ppa
$ sudo apt-get update
$ sudo apt-get install git
相关问题