aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBen Johnson <benbjohnson@yahoo.com>2014-04-11 14:31:34 -0600
committerBen Johnson <benbjohnson@yahoo.com>2014-04-11 14:31:34 -0600
commit714436100adf98a5132e6f4ddb3290231ff89dfd (patch)
tree8a9272322aa759b3d911d3698e6ec21cf71e78d7 /Makefile
parentAdd nested buckets. (diff)
parentMerge pull request #128 from benbjohnson/import-export (diff)
downloaddedo-714436100adf98a5132e6f4ddb3290231ff89dfd.tar.gz
dedo-714436100adf98a5132e6f4ddb3290231ff89dfd.tar.xz
Merge branch 'master' into nested-keys
Conflicts: db_test.go tx_test.go
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 15 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index a87d406..cb44a12 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,9 @@
TEST=.
BENCH=.
COVERPROFILE=/tmp/c.out
+BRANCH=`git rev-parse --abbrev-ref HEAD`
+COMMIT=`git rev-parse --short HEAD`
+GOLDFLAGS="-X main.branch $(BRANCH) -X main.commit $(COMMIT)"
bench: benchpreq
go test -v -test.bench=$(BENCH)
@@ -26,11 +29,23 @@ errcheck:
fmt:
@go fmt ./...
+get:
+ @go get -d ./...
+
+build: get
+ @mkdir -p bin
+ @go build -ldflags=$(GOLDFLAGS) -a -o bin/bolt-`git rev-parse --short HEAD` ./cmd/bolt
+
test: fmt errcheck
+ @go get github.com/stretchr/testify/assert
@echo "=== TESTS ==="
@go test -v -cover -test.run=$(TEST)
@echo ""
@echo ""
+ @echo "=== CLI ==="
+ @go test -v -test.run=$(TEST) ./cmd/bolt
+ @echo ""
+ @echo ""
@echo "=== RACE DETECTOR ==="
@go test -v -race -test.run="TestSimulate_(100op|1000op|10000op)"