If you install Git from the repository on CentOS 6.5, you will get the old version of git v1.7.x. But I need to use a feature that is only available on git v1.8.x or more, for example git pull --recursive, which updates a git repository along with its submodules.
So to fix it, I need to compile git from source. To do that you need to install some of the requirements with the command below:
yum install zlib-devel perl-CPAN gettext
To install Git from source follow the steps below:
cd /var/opt
wget https://git-core.googlecode.com/files/git-1.9.0.tar.gz
tar -xvzf git-1.9.0.tar.gz
cd git-1.9.0.tar.gz
./configure
make
make prefix=/usr install
#Finish installation
#Now we try it
git --version
I have been developing an auto deployment script for me and my team, and now it is working smoothly. I love git 😀
