🎉 A Bitcask Distributed Key/Value store using Raft for consensus with a Redis compatible API written in Go.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
812 B

.PHONY: dev build install image release profile bench test clean lint
VERSION=$(shell git describe --abbrev=0 --tags)
COMMIT=$(shell git rev-parse --short HEAD)
all: dev
dev: build
@./bitraft --version
build: clean
@go build \
-tags "netgo static_build" -installsuffix netgo \
-ldflags "-w -X $(shell go list).Version=$(VERSION) -X $(shell go list).Commit=$(COMMIT)" \
install: build
@go install .
@docker build -t prologic/bitraft .
profile: build
@go test -cpuprofile cpu.prof -memprofile mem.prof -v -bench ./...
bench: build
@go test -v -benchmem -bench=. ./...
test: build
@go test -v -cover -coverprofile=coverage.txt -covermode=atomic -coverpkg=$(shell go list) -race ./...
golangci-lint run
@git clean -f -d -X