diff --git a/generator/add_transport.go b/generator/add_transport.go index e59ef5e..1309419 100644 --- a/generator/add_transport.go +++ b/generator/add_transport.go @@ -22,6 +22,7 @@ import ( "github.com/kujtimiihoxha/kit/parser" "github.com/kujtimiihoxha/kit/utils" "github.com/spf13/viper" + "github.com/emicklei/proto-contrib/pkg/protofmt" ) // GenerateTransport implement Gen, is used to generate a service transport @@ -708,7 +709,7 @@ func (g *generateGRPCTransportProto) Generate() (err error) { } g.generateRequestResponse() buf := new(bytes.Buffer) - formatter := proto.NewFormatter(buf, " ") + formatter := protofmt.NewFormatter(buf, " ") formatter.Format(g.protoSrc) err = g.fs.WriteFile(g.pbFilePath, buf.String(), true) if err != nil { diff --git a/glide.yaml b/glide.yaml index eb75f43..7bb01a3 100644 --- a/glide.yaml +++ b/glide.yaml @@ -22,3 +22,4 @@ import: - imports - package: github.com/emicklei/proto - package: github.com/go-yaml/yaml +- package: github.com/emicklei/proto-contrib