由于Centos 6 自带的GIT 是 1.7 版本的,oschina git 需要 1.8+ 所以进行升级,Centos7 git 是1.8.3的可以不用升级了
下载 wget https://github.com/git/git/archive/v2.11.0.tar.gz
查看 INSTALL 文档就可以完成安装:
进入解压后的目录:
$ make configure
$ ./configure --prefix=/usr --with-curl --with-expat
$ make all doc
# make install install-doc install-html
make的时候遇到问题 :
/bin/sh: line 1: asciidoc: command not found
/bin/sh: line 1: xmlto: command not found
请yum 安装 asciidoc,xmlto 或者 下载安装 asciidoc,xmlto 即可
yum install asciidoc xmlto