-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
51 lines (40 loc) · 961 Bytes
/
Makefile
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
39
40
41
42
43
44
45
46
47
48
49
50
51
NAME=geo-tracking
VERSION="develop"
.PHONY: dep fmt test clean vet
deps:
@echo "Installing dependencies ..."
@go mod tidy && go mod download
@echo "Installing dependencies, done!"
fmt:
@echo "Formatting code ..."
@go fmt ./...
@echo "Formatting code, done!"
test:
@echo "Running tests ..."
@ginkgo -r -cover ./internal
@echo "Running tests, done!"
build: deps clean
@echo "Building ...."
@mkdir -p ./build
@go build -o ./build/$(NAME)
@echo "Build done"
install:
@echo "Installing ..."
@go install
@echo "Installed"
clean:
@echo "Cleaning ..."
@go clean && rm -rf ./build
@echo "Cleaning done"
vet:
@echo "Running vet ..."
@go vet ./...
@echo "Running vet, done!"
infra-up:
@cd infrastructure && docker network create gt || true && docker-compose up -d
infra-down:
@cd infrastructure && docker-compose down
integration-test:
@echo "Running integration-tests ..."
@ginkgo -r -cover ./integration
@echo "Running tests, done!"