tj.git-extras/install.sh
2015-06-08 00:09:40 +08:00

22 lines
456 B
Bash
Executable file

#!/bin/bash
make_install() {
if [ -n "$PREFIX" ]
then
PREFIX="$PREFIX" make install
else
sudo make install
fi
}
cd /tmp \
&& rm -rf ./git-extras \
&& echo "Setting up 'git-exras'...." \
&& git clone https://github.com/tj/git-extras.git &> /dev/null \
&& cd git-extras \
&& git checkout \
$(git describe --tags $(git rev-list --tags --max-count=1)) \
&> /dev/null \
&& make_install