2014-02-28 100 views

回答

1

获取的git的最新vesion从以下位置 https://github.com/git/git/releases

登录到您的主机,并在你的主文件夹,运行以下命令..

curl -O http://github.com/git/git/archive/v1.8.3.3.tar.gz(put the latest vesion of git) 
tar zxvf git-1.8.3.3.tar.gz 
cd git-1.8.3.3 
./configure --prefix=/home/$USER --with-curl --with-expat 
make -i 
make -i install 
echo 'PATH=$PATH:$HOME/bin' >> $HOME/.bashrc 
source $HOME/.bashrc 

然后键入git版本它会给git版本1.8.3

+0

后续问题先生,我偶然发现了你所做的同样的答案,但是我的共享主机似乎没有激活curl命令。我如何激活它?谢谢! – sprint