Skip to content

Instantly share code, notes, and snippets.

@abma abma/compile.sh
Created Mar 21, 2012

Embed
What would you like to do?
spring install script
#!/bin/sh
set -e
if [ $# -eq 0 ]; then
echo Usage: $0 path/to/install [git revision]
exit 1
fi
if [ $# -eq 2 ]; then
REVISION='origin/master'
else
REVISION=$2
fi
INSTPATH=$1
REPO=/tmp/spring
if [ -d $REPO/.git ]; then
cd $REPO
git fetch
else
git clone git://github.com/spring/spring.git $REPO
fi
cd $REPO
git clean -f -d
git reset --hard $REVISION
cmake . -DCMAKE_INSTALL_PREFIX=$INSTPATH
make -j2 install-spring
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.