Skip to content

Instantly share code, notes, and snippets.

@fivesmallq
Forked from eyecatchup/mkgit-centos6.sh
Last active September 19, 2017 10:55
Show Gist options
  • Select an option

  • Save fivesmallq/efdd7bdf5c8d1602f8e12af40802aa1f to your computer and use it in GitHub Desktop.

Select an option

Save fivesmallq/efdd7bdf5c8d1602f8e12af40802aa1f to your computer and use it in GitHub Desktop.

Revisions

  1. fivesmallq revised this gist Sep 19, 2017. 1 changed file with 10 additions and 0 deletions.
    10 changes: 10 additions & 0 deletions mkgitlfs-centos6.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    #!/usr/bin/env bash
    # https://github.com/git-lfs/git-lfs/wiki/Installation
    # Install the IUS Community repo.
    curl -s https://setup.ius.io/ | sudo bash
    sudo yum install git2u
    # download git lfs rpm
    wget https://packagecloud.io/github/git-lfs/packages/el/6/git-lfs-2.3.0-1.el6.x86_64.rpm/download
    mv download git-lfs-2.3.0-1.el6.x86_64.rpm
    rpm -ivh git-lfs-2.3.0-1.el6.x86_64.rpm
    git lfs install
  2. @eyecatchup eyecatchup created this gist Jun 26, 2015.
    25 changes: 25 additions & 0 deletions mkgit-centos6.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,25 @@
    #!/usr/bin/env bash
    # Install the latest version of git on CentOS 6.x

    # Install Required Packages
    sudo yum install curl-devel expat-devel gettext-devel openssl-devel zlib-devel
    sudo yum install gcc perl-ExtUtils-MakeMaker

    # Uninstall old Git RPM
    sudo yum remove git

    # Download and Compile Git Source
    cd /usr/src
    sudo wget https://www.kernel.org/pub/software/scm/git/git-2.4.4.tar.gz
    sudo tar xzf git-2.4.4.tar.gz

    cd git-2.4.4
    sudo make prefix=/usr/local/git all
    sudo make prefix=/usr/local/git install

    echo "export PATH=$PATH:/usr/local/git/bin" >> /etc/bashrc
    sudo ln -s /usr/local/git/bin/git /usr/bin/git
    source /etc/bashrc

    # Check Git Version
    git --version