CentOS安装Git
githut已经逐渐成为开源代码管理的主流趋势,git并没有CentOS的直接安装方法,可能CentOS的yum源也不是最新的,可以通过下载源代码编译安装,安装前注意要安装gcc和zlib
wgethttps://www.kernel.org/pub/software/scm/git/git-2.9.0.tar.gz
tar-xzvfgit-2.9.0.tar.gz
cdgit-2.9.0.tar.gz
./configure
make&&makeinstall
git--version
gitversion2.9.0
说明安装成功了
make时候碰见错误
usr/local/git/share/locale'
Can'tlocateExtUtils/MakeMaker.pmin@INC(@INCcontains:/usr/local/lib/perl5/usr/local/share/perl5/usr/lib/perl5/vendor_perl/usr/share/perl5/vendor_perl/usr/lib/perl5/usr/share/perl5.)atMakefile.PLline3.
BEGINfailed--compilationabortedatMakefile.PLline3.
解决:yuminstallperl-ExtUtils-MakeMaker
tclshfailed;usingunoptimizedloading
MSGFMTpo/de.msgmake[1]:***[po/de.msg]Error127
解决:yuminstalltcl
/bin/sh:msgfmt:commandnotfound
make:***[po/build/locale/da/LC_MESSAGES/git.mo]Error127
解决:yuminstallgettext-devel
gitclone时候提示fatal:Unabletofindremotehelperfor'https'
解决:yuminstalllibcurl-devel