-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
37 lines (30 loc) · 954 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
.PHONY: install
install:
go install github.com/google/wire/cmd/wire@latest \
&& go install google.golang.org/protobuf/cmd/protoc-gen-go@latest \
&& go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest \
&& go install github.com/srikrsna/protoc-gen-gotag@latest
.PHONY: run-http
run-http:
go run ./cmd/gskeleton run-http -config ./configs/gskeleton.yaml
.PHONY: run-grpc
run-grpc:
go run ./cmd/gskeleton run-grpc -config ./configs/gskeleton.yaml
.PHONY: cli-migrate
cli-migrate:
go run ./cmd/gskeleton cli-migrate -config ./configs/gskeleton.yaml
test:
go test -v ./...
.PHONY: build
build:
go build -o ./build/gskeleton ./cmd/gskeleton
.PHONY: proto
proto:
protoc --proto_path ./api/grpc/proto \
--go_out=paths=source_relative:./api/grpc/pb \
--go-grpc_out=paths=source_relative:./api/grpc/pb \
./api/grpc/proto/*.proto
.PHONY: install-ubuntu
install-ubuntu:
apt install -y protobuf-compiler
protoc --version