朱亮亮

Stay Hungry, Stay Foolish.

0%

go get installing executables with 'go get' in module mode is deprecated.

最近开始学习 GO 相关的知识,在入门 kitex 时,需要使用 go get 安装,虽然安装成功了,但是有如下提示

1
2
3
4
5
go get: installing executables with 'go get' in module mode is deprecated.
To adjust and download dependencies of the current module, use 'go get -d'.
To install using requirements of the current module, use 'go install'.
To install ignoring the current module, use 'go install' with a version,
like 'go install example.com/cmd@latest'.

这是因为在最新版 GO(1.17),go get 不再支持了,要想安装支持包,我们可以使用 go install,例如安装 kitex 可以使用如下命令:

1
go install github.com/cloudwego/kitex/tool/cmd/kitex@latest