本文共 591 字,大约阅读时间需要 1 分钟。
由于Centos7使用yum -y install git 安装的git版本是
git --versiongit version 1.9.x想要升级到2.10.0:升级安装git的时候,最好一次安装依赖。yum install -y tk zlib-devel openssl-devel perl cpio expat-devel gettext-devel asciidoc xmltoyum install perl-ExtUtils-MakeMaker packageyum remove gitwget tar zxvf v2.10.0.tar.gzcd git-2.10.0make configure./configure --prefix=/usr/local/git --with-iconv=/usr/local/libiconvmake all docmake install install-doc install-htmlecho "export PATH=$PATH:/usr/local/git/bin" >> /etc/bashrcsource /etc/bashrcgit --versiongit version 2.10.0
转载于:https://blog.51cto.com/12276890/2103118