-
Notifications
You must be signed in to change notification settings - Fork 148
Expand file tree
/
Copy pathMakefile
More file actions
38 lines (29 loc) · 788 Bytes
/
Copy pathMakefile
File metadata and controls
38 lines (29 loc) · 788 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
#
# SPDX-License-Identifier: BSD-3-Clause
#
PKGS := $(shell go list ./... | grep -v example | grep -v tools)
ROOT_DIR := $(shell git rev-parse --show-toplevel)
GOLANGCI_VERSION := "v2.6.2"
all: lint build test
test:
go test -v $(PKGS) -cover -race
build:
go build
lint:
docker run --rm \
-v "$(ROOT_DIR)":/src \
-w /src \
"golangci/golangci-lint:$(GOLANGCI_VERSION)" \
golangci-lint run -v
fmt:
docker run --rm \
-v "$(ROOT_DIR)":/src \
-w /src \
"golangci/golangci-lint:$(GOLANGCI_VERSION)" \
golangci-lint fmt .
OUTPUT_DIR ?= ../..
generate:
cd tools/generator && \
go run ./cmd/generate-schemas --output-dir $(OUTPUT_DIR)
clean:
go clean