diff --git a/cmd/kratos/internal/proto/add/template.go b/cmd/kratos/internal/proto/add/template.go index 805596777..c518a1760 100644 --- a/cmd/kratos/internal/proto/add/template.go +++ b/cmd/kratos/internal/proto/add/template.go @@ -16,11 +16,11 @@ option java_multiple_files = true; option java_package = "{{.JavaPackage}}"; service {{.Service}} { - rpc Create{{.Service}} (Create{{.Service}}Request) returns (Create{{.Service}}Reply); - rpc Update{{.Service}} (Update{{.Service}}Request) returns (Update{{.Service}}Reply); - rpc Delete{{.Service}} (Delete{{.Service}}Request) returns (Delete{{.Service}}Reply); - rpc Get{{.Service}} (Get{{.Service}}Request) returns (Get{{.Service}}Reply); - rpc List{{.Service}} (List{{.Service}}Request) returns (List{{.Service}}Reply); + rpc Create{{.Service}} (Create{{.Service}}Request) returns (Create{{.Service}}Reply); + rpc Update{{.Service}} (Update{{.Service}}Request) returns (Update{{.Service}}Reply); + rpc Delete{{.Service}} (Delete{{.Service}}Request) returns (Delete{{.Service}}Reply); + rpc Get{{.Service}} (Get{{.Service}}Request) returns (Get{{.Service}}Reply); + rpc List{{.Service}} (List{{.Service}}Request) returns (List{{.Service}}Reply); } message Create{{.Service}}Request {} diff --git a/cmd/kratos/internal/proto/server/template.go b/cmd/kratos/internal/proto/server/template.go index 54ca81690..f394322d7 100644 --- a/cmd/kratos/internal/proto/server/template.go +++ b/cmd/kratos/internal/proto/server/template.go @@ -11,16 +11,16 @@ package service import ( {{- if .UseContext }} - "context" + "context" {{- end }} {{- if .UseIO }} "io" {{- end }} - pb "{{ .Package }}" - {{- if .GoogleEmpty }} - "google.golang.org/protobuf/types/known/emptypb" - {{- end }} + pb "{{ .Package }}" + {{- if .GoogleEmpty }} + "google.golang.org/protobuf/types/known/emptypb" + {{- end }} ) type {{ .Service }}Service struct {