您的位置:首页 > 其它

MacOS安装和升级protobuf

2021-04-26 01:34 7177 查看

团队的新手同学连grpc的环境都搭不起来, 也就有了本篇简单的教程。

GRpc根本用到的俩个东西: protobuf&protoc-gen-go

protoc的安装

MacOS 并不需要复杂的安装

brew info protobuf //查看现有protobuf包
brew install protobuf //安装protobuf
protoc --version //查看protobuf版本

因我的版本比他的低,所以我需要更新最新版本。

brew uninstall protobuf --force //卸载原有
brew update
brew info //查看版本一致,跟他一致
brew install protobuf


protoc-gen-go 的安装

https://github.com/golang/protobuf

go get -u github.com/golang/protobuf/protoc-gen-go


扩展阅读



内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: