2015-02-06 76 views

回答

1

你有一个令人惊讶的新版本的git。这不是为CentOS 6或7正式打包的。

CentOS 6附带git 1.7.1。

CentOS 7附带1.8.3.1。

要得到一个较新版本的git,你需要找出你已经有了“新”版本的git,看看它们是否有更新。亚马逊本身可能已经打包了一个更新的版本,可能还没有更新过该软件包。

从的yum info git输出(从评论):

$ yum info git 
Loaded plugins: priorities, update-motd, upgrade-helper 
Installed Packages 
Name : git 
Arch : x86_64 
Version : 2.1.0 
Release : 1.35.amzn1 
Size : 22 M 
Repo : installed 
From repo : amzn-main 
Summary : Fast Version Control System 
URL : git-scm.com 
License : GPLv2 
Description : Git is a fast, scalable, distributed revision control system with an 
      : unusually rich command set that provides both high-level operations 
      : and full access to internals. 

看来,亚马逊已经打包的2.1版git自己,如果yum update不会让你一个新的版本,那么他们没有任何包装那么版本更新。

Amazon Linux AMIrelease notes页似乎同意这一点。

+0

如何找出哪个存储库在Linux AMI中提供了当前的git 2.1版本? – Rpj 2015-02-08 08:42:48

+0

@Rpj我要求的输出将是一个有用的开始。另外'yum info git'。 – 2015-02-08 22:36:41

+0

_gitpath = $(command -v git);回声“$ _gitpath”; RPM -qf “$ _gitpath” 在/ usr/bin中/混帐 混帐2.1.0-1.35.amzn1.x86_64 – Rpj 2015-02-11 10:51:44