C/C++教程

centos7安装高版本git

本文主要是介绍centos7安装高版本git,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

git获取地址:

https://github.com/git/git/releases
https://www.kernel.org/pub/software/scm/git/

1.安装依赖

yum install curl-devel expat-devel gettext-devel openssl-devel zlib-devel 
yum install gcc-c++ perl-ExtUtils-MakeMaker

yum remove git

2.下载高版本git,并且安装

wget https://www.kernel.org/pub/software/scm/git/git-2.7.3.tar.gz

tar -zxvf git-2.7.3.tar.gz
cd git-2.7.3
./configure --prefix=/usr/local/git
make && make install

ln -s /usr/local/git/bin/git /usr/bin/git

 

这篇关于centos7安装高版本git的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!