forked from couchbase/sync_gateway
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·35 lines (23 loc) · 769 Bytes
/
build.sh
File metadata and controls
executable file
·35 lines (23 loc) · 769 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/sh -e
# This script builds sync gateway using pinned dependencies via the repo tool
#
# - Set GOPATH and call 'go install' to compile and build Sync Gateway binaries
if [ -d "godeps" ]; then
export GOPATH=`pwd`/godeps
fi
updateVersionStamp () {
# Build path to SG code directory
SG_DIR=$GOPATH/src/github.com/couchbase/sync_gateway
# Save the current directory
CURRENT_DIR=`pwd`
# Cd into SG code directory
cd $SG_DIR
./set-version-stamp.sh
# Go back to the original current directory
cd $CURRENT_DIR
}
updateVersionStamp
## Go Install
echo "Building code with 'go install' ..."
go install "$@" github.com/couchbase/sync_gateway/...
echo "Success! Output is godeps/bin/sync_gateway and godeps/bin/sg_accel "