protoc-gen-go.exe安装
来源:16-5 go下grpc快速体验 - 1

慕圣3342745
2021-02-13
protoc-gen-go时的问题。。。执行go get github.com/golang/protobuf/protoc-gen-go,报错:Get “https://proxy.golang.com.cn/github.com/golang/protobuf/@v/v1.4.3.zip”: stopped after 10 redirects
网上查了google.golang.org/protobuf/cmd/protoc-gen-go命令,可以生成protoc-gen-go.exe,但是不支持protoc -I . goods.proto --go_out=plugins=grpc:.命令
2回答
-
Yao_Jerry
2021-04-27
我也执行报错,请问你是怎么解决的呢
C:\Users\Administrator>go get github.com/golang/protobuf/protoc-gen-go
go: found github.com/golang/protobuf/protoc-gen-go in github.com/golang/protobuf v1.5.2
go\pkg\mod\google.golang.org\protobuf@v1.26.0\compiler\protogen\protogen.go:14:2: package bufio is not in GOROOT (C:\Users\Administrator\go\src\bufio)
go\pkg\mod\google.golang.org\protobuf@v1.26.0\compiler\protogen\protogen.go:15:2: package bytes is not in GOROOT (C:\Users\Administrator\go\src\bytes)
go\pkg\mod\google.golang.org\protobuf@v1.26.0\internal\impl\legacy_file.go:9:2: package compress/gzip is not in GOROOT (C:\Users\Administrator\go\src\compress\gzip)
go\pkg\mod\google.golang.org\protobuf@v1.26.0\internal\detrand\rand.go:13:2: package encoding/binary is not in GOROOT (C:\Users\Administrator\go\src\encoding\binary)
........
052021-04-28 -
慕圣3342745
提问者
2021-02-15
已解决
012021-02-16
相似问题