繁体   English   中英

ubuntu 18.04.2LTS安装git提示错误

[英]Error showing in the installation of git in ubuntu 18.04.2LTS

我正在尝试通过命令安装 git。

sudo apt install git

显示错误:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 git : Depends: liberror-perl but it is not going to be installed
       Depends: git-man (> 1:2.17.1) but it is not going to be installed
       Depends: git-man (< 1:2.17.1-.) but it is not going to be installed
 mongodb-org : Depends: mongodb-org-server but it is not going to be installed
               Depends: mongodb-org-mongos but it is not going to be installed
               Depends: mongodb-org-tools but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

此外,尝试运行命令apt --fix-broken install但没有奏效。

首先尝试使用sudo apt-get upgrade更新所有现有软件包。 之后,您可能想要运行sudo apt-get autoclean 最后再次安装 git sudo apt-get install git

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install git

我认为你需要在那里看到:我使用 ubuntu 20.04,但它为我运行。

https://linuxize.com/post/how-to-install-git-on-ubuntu-18-04/

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM