-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathMakefile
More file actions
30 lines (24 loc) · 757 Bytes
/
Copy pathMakefile
File metadata and controls
30 lines (24 loc) · 757 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
compose = docker-compose -f build/docker-compose.yml
.PHONY: build
build: ##@development Build development environment.
$(compose) build
.PHONY: up
up: build ##@development Starts development environment in background.
$(compose) up -d
.PHONY: test
test: build ##@development Runs the tests.
$(compose) run --rm app go test ./...
.PHONY: logs
logs: ##@development Follows development logs.
$(compose) logs -f --tail=100
lint_version ?= v1.40-alpine
.PHONY: lint
lint: ##@development Runs static analysis.
docker run --rm \
-w /app \
-v $(shell pwd):/app \
golangci/golangci-lint:$(lint_version) \
golangci-lint run --timeout 3m
.PHONY: clean
clean: ##@development Stop development environment.
$(compose) down --volumes --remove-orphans