mirror of
https://github.com/status-im/keycard-cli.git
synced 2025-03-01 04:10:33 +00:00
add Makefile
This commit is contained in:
parent
5ba1397f33
commit
7081eccf5c
21
Makefile
Normal file
21
Makefile
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
.PHONY: test build
|
||||||
|
|
||||||
|
GOBIN = $(dir $(realpath $(firstword $(MAKEFILE_LIST))))build/bin
|
||||||
|
PROJECT_NAME=keycard-cli
|
||||||
|
GO_PROJECT_PATH=github.com/status-im/$(PROJECT_NAME)
|
||||||
|
BIN_NAME=keycard
|
||||||
|
DOCKER_IMAGE_NAME=keycard
|
||||||
|
|
||||||
|
build:
|
||||||
|
go build -i -o $(GOBIN)/$(BIN_NAME) -v .
|
||||||
|
@echo "Compilation done."
|
||||||
|
@echo "Run \"./build/bin/$(BIN_NAME) -h\" to view available commands."
|
||||||
|
|
||||||
|
test:
|
||||||
|
go test -v ./...
|
||||||
|
|
||||||
|
build-docker-image:
|
||||||
|
docker build -t $(DOCKER_IMAGE_NAME) -f _assets/Dockerfile .
|
||||||
|
|
||||||
|
build-platforms:
|
||||||
|
xgo -image $(DOCKER_IMAGE_NAME) --dest $(GOBIN) --targets=linux/amd64,windows/amd64 ./cmd/$(BIN_NAME)
|
Loading…
x
Reference in New Issue
Block a user