mirror of
https://github.com/go-kratos/kratos.git
synced 2025-01-26 03:52:12 +02:00
fix(makefile): add "make proto" for proto generating (#2130)
Co-authored-by: Guoqiang Ding <guoqiang10@staff.sina.com.cn>
This commit is contained in:
parent
e176ddfcdd
commit
667d63839c
7
Makefile
7
Makefile
@ -76,4 +76,9 @@ test-coverage:
|
||||
.PHONY: lint
|
||||
lint: $(LINTER)
|
||||
@${TOOLS_SHELL} lint
|
||||
@echo "lint check finished"
|
||||
@echo "lint check finished"
|
||||
|
||||
.PHONY: proto
|
||||
proto:
|
||||
protoc --proto_path=./api --proto_path=./third_party --go_out=paths=source_relative:./api --go-grpc_out=paths=source_relative:./api --go-http_out=paths=source_relative:./api metadata/metadata.proto
|
||||
protoc --proto_path=./third_party --go_out=paths=source_relative:./ errors/errors.proto
|
||||
|
@ -20,9 +20,6 @@ import (
|
||||
dpb "google.golang.org/protobuf/types/descriptorpb"
|
||||
)
|
||||
|
||||
//nolint:lll
|
||||
//go:generate protoc --proto_path=. --proto_path=../../third_party --go_out=paths=source_relative:. --go-grpc_out=paths=source_relative:. --go-http_out=paths=source_relative:. metadata.proto
|
||||
|
||||
// Server is api meta server
|
||||
type Server struct {
|
||||
UnimplementedMetadataServer
|
||||
|
@ -9,8 +9,6 @@ import (
|
||||
"google.golang.org/grpc/status"
|
||||
)
|
||||
|
||||
//go:generate protoc -I. --go_out=paths=source_relative:. errors.proto
|
||||
|
||||
const (
|
||||
// UnknownCode is unknown code for error info.
|
||||
UnknownCode = 500
|
||||
|
Loading…
x
Reference in New Issue
Block a user