Created
February 14, 2013 18:47
-
-
Save dustin/4955187 to your computer and use it in GitHub Desktop.
cbugg build script
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/sh -e | |
| export GOPATH=$HOME/go | |
| export PATH=/bin:/usr/bin:/usr/local/bin:$HOME/go/bin:$HOME/prog/go/bin | |
| cd $HOME/go/src/github.com/couchbaselabs/cbugg | |
| git fetch origin | |
| if git diff --name-only origin/master | fgrep -q .go | |
| then | |
| echo "There were changes in the go code, doing an up + build" | |
| go get -u | |
| go build | |
| else | |
| echo "No changes in the go code, just restarting." | |
| git reset --hard origin/master | |
| fi | |
| git rev-parse HEAD > static/version |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment