Created
October 4, 2015 05:52
-
-
Save bootleq/ace01249ebd145784557 to your computer and use it in GitHub Desktop.
Install tig from source
This file contains hidden or 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
#!/bin/bash | |
if which apt-get 2>&1 >/dev/null; then | |
[[ -z $(dpkg --get-selections | grep libncursesw5-dev) ]] && sudo apt-get install -y libncursesw5-dev | |
elif which brew 2>&1 >/dev/null; then | |
brew install tig --with-docs | |
exit | |
fi | |
cd ~/src | |
[[ ! -d tig ]] && git clone git://github.com/jonas/tig.git --depth 10 | |
cd tig | |
git fetch origin tig-2.1.1 --depth 1 | |
git checkout FETCH_HEAD | |
make configure | |
./configure | |
# install for all users | |
make prefix=/usr/local all | |
sudo make prefix=/usr/local install | |
sudo make install-release-doc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment