Created
July 21, 2017 16:19
-
-
Save igorferreira/47af1b4452807068e7848c69f1c09c7d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# dependencias git | |
sudo yum install autoconf libcurl-devel expat-devel gcc gettext-devel kernel-headers openssl-devel perl-devel zlib-devel -y | |
# remove git | |
rpm -qa | grep "git" | |
rpm -e --nodeps "git-1.8.3.1-6.el7_2.1.x86_64" | |
# create dirs | |
mkdir -p /opt/git/src | |
# download | |
cd /opt/git | |
wget https://www.kernel.org/pub/software/scm/git/git-2.9.4.tar.gz | |
mv git-2.9.4.tar.gz ./src | |
# descompact | |
tar xzf git-2.9.4.tar.gz | |
# link para pasta de sistema | |
cd /usr/src | |
sudo ln -s /opt/git/src/git-2.9.4 git-2.9.4 | |
# compila | |
make clean | |
make configure | |
./configure --prefix=/usr/local/git | |
make prefix=/usr/local/git all | |
make prefix=/usr/local/git install | |
# adiciona no bashrc | |
echo "export PATH=$PATH:/usr/local/git/bin" >> /etc/bashrc | |
source /etc/bashrc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment