Created
August 22, 2012 14:38
-
-
Save haf/3426227 to your computer and use it in GitHub Desktop.
Installing git and git-subtree from source in ubuntu as packages
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
# use with: curl -L https://raw.github.com/gist/3426227 | bash | |
# get git binary, then git with git | |
sudo apt-get install git -y | |
git clone https://github.com/git/git.git | |
# remove your binary/package | |
sudo apt-get remove git -y | |
sudo apt-get install make checkinstall libcurl4-gnutls-dev libexpat1-dev gettext libz-dev libssl-dev asciidoc -y | |
# build git & install it | |
cd git | |
make prefix=/usr/local all | |
sudo checkinstall --pkgname=git make prefix=/usr/local install | |
# build subtree & install it | |
cd contrib/subtree | |
make prefix=/usr/local | |
sudo checkinstall --pkgname=git-subtree make prefix=/usr/local install | |
sudo checkinstall --pkgname=git-subtree-doc make prefix=/usr/local install-doc | |
# clean up afterwards | |
sudo apt-get remove -y libcurl4-gnutls-dev libexpat1-dev gettext libz-dev libssl-dev asciidoc | |
sudo apt-get autoremove -y |
PS, if you don't have that box:
vagrant box add precise32 http://files.vagrantup.com/precise32.box
It seems there is something wrong with gist urls, this works now
curl -L https://gist.github.com/haf/3426227/raw/b9a3037a319d31c8bd898760331c4e4c2824ddce/install-git.sh | bash
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Test it with vagrant!