CentOS5.X 下安装Git

Centos6.X可以通过yum方式安装,发现5.x yum源里没有。

 

首先需要安装git的依赖包

 

yum install curl
yum install curl-devel
yum install zlib-devel
yum install openssl-devel
yum install perl
yum install cpio
yum install expat-devel
yum install gettext-devel
 
 
下载最新的git包
wget http://www.codemonkey.org.uk/projects/git-snapshots/git/git-latest.tar.gz
tar xzvf git-latest.tar.gz
cd git-xxxx-xx-xx
autoconf
./configure
make | make install
 
验证是否安装成功:检查安装的版本
git –version
 
来源:http://www.zhourongyu.info/centos-install-git/
posted on 2012-09-04 16:40  马德华  阅读(224)  评论(0编辑  收藏  举报