如何解决使用gRPC、Go和protoc时的路径问题?

huangapple go评论63阅读模式
英文:

how to fix path problem with grpc, go and protoc

问题

有没有修复运行protoc命令时超出go路径的方法。就像我必须为每个新项目导出路径一样...

$ export PATH="$PATH:$(go env GOPATH)/bin"

英文:

is there any fix fro running protoc command for go outside go path. Like I have to export path for every new project...

$ export PATH="$PATH:$(go env GOPATH)/bin"

答案1

得分: 0

只需要将这段代码添加到.zshrc或.bashrc文件中即可。

英文:

just needed to add this to the .zshrc or .bashrc file

huangapple
  • 本文由 发表于 2022年1月8日 03:20:06
  • 转载请务必保留本文链接:https://go.coder-hub.com/70626152.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定