commit-bot@chromium.org | 5132461 | 2014-05-13 18:03:45 +0000 | [diff] [blame] | 1 | if [[ -z `which go` ]]; then |
| 2 | echo "Please install Go before running the server." |
| 3 | exit 1 |
| 4 | fi |
| 5 | |
commit-bot@chromium.org | 0fd0d4c | 2014-05-14 15:42:14 +0000 | [diff] [blame] | 6 | if [[ -z "$GOPATH" ]]; then |
| 7 | echo "GOPATH environment variable is not set. Please see" |
| 8 | echo "http://golang.org/doc/code.html#GOPATH for more information." |
| 9 | exit 1 |
| 10 | fi |
| 11 | |
commit-bot@chromium.org | 5132461 | 2014-05-13 18:03:45 +0000 | [diff] [blame] | 12 | go get github.com/gorilla/securecookie |
commit-bot@chromium.org | f364521 | 2014-05-14 16:57:49 +0000 | [diff] [blame] | 13 | go get code.google.com/p/goauth2/oauth |
commit-bot@chromium.org | 5132461 | 2014-05-13 18:03:45 +0000 | [diff] [blame] | 14 | |
| 15 | DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" |
| 16 | cd $DIR |
commit-bot@chromium.org | 44d4210 | 2014-05-13 19:18:55 +0000 | [diff] [blame] | 17 | |
| 18 | if [[ ! -f oauth_client_secret.json ]]; then |
| 19 | gsutil cp gs://chromium-skia-gm/bugchomper/oauth_client_secret.json . |
| 20 | fi |
| 21 | |
commit-bot@chromium.org | 5132461 | 2014-05-13 18:03:45 +0000 | [diff] [blame] | 22 | GOPATH="$GOPATH:$DIR" go run $DIR/src/server/server.go $@ |
| 23 | |