Skip to content

Instantly share code, notes, and snippets.

@michelson
Created July 14, 2014 21:52
Show Gist options
  • Save michelson/47fe48fe5ca4dc524f15 to your computer and use it in GitHub Desktop.
Save michelson/47fe48fe5ca4dc524f15 to your computer and use it in GitHub Desktop.
set -e
cd "`dirname '$0'`"
SCRIPTPATH="`pwd`"
cd - > /dev/null
export GOPATH=$SCRIPTPATH
export GOBIN=
function deps {
echo "Fetching dependencies to $SCRIPTPATH..."
printf "### (00/03)\r"
go get -u -t github.com/barakmich/glog
printf "##### (01/03)\r"
go get -u -t github.com/looplab/fsm
printf "###### (02/03)\r"
printf "######## (03/03)\r"
go get -u -t bitbucket.org/kardianos/osext
printf "\n"
}
function build {
go build godard
}
#function run {
# go build godard ; ./godard
#}
function run {
go build godard ; ./godard load --config=./godard.cfg
}
$1
default: build
build:
./make.sh build
run:
./make.sh run
deps:
./make.sh deps
test:
ls ./src | grep -v "\." | sed 's/\///g' | xargs go test -cover
convey:
./bin/goconvey --depth=2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment