如果我有 go 1.7 版本,我怎么知道我正在使用哪个次要版本?

发布于 2025-01-14 00:06:18 字数 342 浏览 3 评论 0原文

我对GO一无所知,我从未使用过它。但我帮助了一个团队,他们需要更新他们的项目。

最近发现了一个错误,他们必须将 go 的版本更新到 1.17.8,但在 go.mod 中我看到他们使用 1.17。

如果我输入 1.17.8,我会收到格式错误,因为它必须是 XX,不能是 XXX,我如何知道我正在使用哪个版本的 minior?或者我如何确定我使用的是正确的版本。

go 1.17.8  //Compile Error -> go version '1.17.8': must match format 1.23 (I NEED THIS ONE)
go 1.17  //Compile OK

I have no idea about GO, I have never worked with it. But I have helped a team and they need to update their project.

Recently a bug has been found and they have to update the version of go to 1.17.8 but in the go.mod I see that they use 1.17.

if I put 1.17.8 I get a format error because it must be X.X it can't be X.X.X, how do I know which version of minior I'm using? or how can I be sure I'm using the correct version.

go 1.17.8  //Compile Error -> go version '1.17.8': must match format 1.23 (I NEED THIS ONE)
go 1.17  //Compile OK

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

美胚控场 2025-01-21 00:06:18

[H]我如何确定我使用的是正确的版本。

通过安装正确的版本。 go.mod 中的 go 指令对您的安装没有影响。

[H]ow can I be sure I'm using the correct version.

By installing the correct version. The go directive in go.mod has no influence on your installation.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文