-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
18 lines (16 loc) · 876 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
gentool:
go build -a -o ./tools ./cmd/protoc-gen-chat
genpb:
rm -rf pbk/pb/message_obj/*.pb.go
rm -rf pkg/pb/message_cli/*.pb.go pkg/pb/message_cli/*.ext.go
rm -rf pkg/pb/message_rpc/*.pb.go pkg/pb/message_rpc/*.ext.go
rm -rf internal/inter/rpcinter/*.inter.go
rm -rf internal/api/*.cli.go
rm -rf internal/rpc/*.svr.go
./tools/protoc --proto_path=protos/ --plugin=protoc-gen-go=./tools/protoc-gen-go \
--go_out=paths=source_relative:./pkg/pb/ \
protos/message_cli/* protos/message_rpc/* protos/message_obj/*
./tools/protoc --proto_path=protos/ --plugin=protoc-gen-chat=./tools/protoc-gen-chat \
--chat_out=cli="pkg/pb":. protos/message_cli/*
./tools/protoc --proto_path=protos/ --plugin=protoc-gen-chat=./tools/protoc-gen-chat \
--chat_out=rpcext="pkg/pb",rpccli="internal/api",rpcinter="internal/inter/rpcinter",rpcsvr=internal/rpc:. protos/message_rpc/*