环境:
Linux PBCS-IN-LIB 2.6.18-194.el5 #1 SMP Tue Mar 16 21:52:39 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux
git下载地址:https://www.kernel.org/pub/software/scm/git/
安装:
tar -xzf git-2.1.3.tar.gz
cd git-2.1.3
./configure -prefix=/usr/local/git --with-curl --with-expat
make && make install
修改参数
修改/etc/profile,在PATH中加入git路径,并执行 source /etc/profile
GIT_HOME=/usr/local/git
PATH=$PATH:$GIT_HOME/bin:$GIT_HOME/libexec/git-core
export PATH GIT_HOME
git --version
git-svn 安装需要依赖subversion-perl
1. Subversion的版本信息
# rpm -qf `which svn`
subversion-1.4.2-4.el5_3.1
2.检查操作系统信息
[root@PBCS-IN-LIB git]# uname -i
x86_64
3.查找rpm包,安装rpm
rpm -ivh subversion-perl-1.4.2-4.el5_3.1.x86_64.rpm
Gitweb安装
安装lighttpd ,http://www.lighttpd.net下载源码进行安装
./configure --prefix=/usr/local/lighttpd
make && make install
启动
git instaweb --httpd=/usr/local/lighttpd/sbin/lighttpd