2014-01-09 08:47:45 +04:00
|
|
|
#!/bin/sh -e
|
2013-07-11 02:37:17 +04:00
|
|
|
|
2014-04-09 20:51:58 +04:00
|
|
|
if [ ! -h gopath/src/github.com/coreos/etcd ]; then
|
|
|
|
mkdir -p gopath/src/github.com/coreos/
|
|
|
|
ln -s ../../../.. gopath/src/github.com/coreos/etcd
|
2014-02-02 11:06:14 +04:00
|
|
|
fi
|
|
|
|
|
|
|
|
export GOBIN=${PWD}/bin
|
2014-04-09 20:51:58 +04:00
|
|
|
export GOPATH=${PWD}/gopath
|
2014-04-04 22:19:04 +04:00
|
|
|
export GOFMTPATH="./bench ./config ./discovery ./etcd ./error ./http ./log main.go ./metrics ./mod ./server ./store ./tests"
|
2014-03-31 23:18:57 +04:00
|
|
|
|
|
|
|
# Don't surprise user by formatting their codes by stealth
|
2014-04-04 22:19:04 +04:00
|
|
|
if [ "--fmt" = "$1" ]; then
|
2014-03-31 23:18:57 +04:00
|
|
|
gofmt -s -w -l $GOFMTPATH
|
|
|
|
fi
|
2014-02-02 11:06:14 +04:00
|
|
|
|
|
|
|
go install github.com/coreos/etcd
|
|
|
|
go install github.com/coreos/etcd/bench
|