-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
38 lines (27 loc) · 933 Bytes
/
Copy pathMakefile
File metadata and controls
38 lines (27 loc) · 933 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
35
36
37
38
# Get the currently used golang install path (in GOPATH/bin, unless GOBIN is set)
ifeq (,$(shell go env GOBIN))
GOBIN=$(shell go env GOPATH)/bin
else
GOBIN=$(shell go env GOBIN)
endif
SHELL = /usr/bin/env bash -o pipefail
#.SHELLFLAGS = -ec
ROOT_DIR:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
all: build
##@ Development
fmt: ## Run gofumpt against code.
gofumpt -l -w .
vet: ## Run go vet against code.
go vet ./...
test: fmt vet envtest ## Run tests.
go test -v ./... -coverprofile cover.out
lint: ## Run golangci-lint against code.
golangci-lint run --path-prefix=.
build: fmt vet ## Build avalanche CLI binary.
scripts/build.sh
run: build ## Run avalanche CLI
./bin/avalanche help
docker: ## check docker
docker --version || (echo "docker is not installed. Pls follow https://docs.docker.com/get-docker/" && exit 1)
docker-build: docker ## Build docker image
docker build . -t avalanche-cli