duanjiaolia97750
2019-04-11 06:49
浏览 227
已采纳

在哪里可以找到golang模块?

I am from node.js ecosystem.

Golang has released its module system finally and I have read some articles about it:

But, after that, I still didn't find a place like npmjs.com where I can find available go modules.

图片转代码服务由CSDN问答提供 功能建议

我来自node.js生态系统。

Golang终于发布了其模块系统,我已经阅读了一些有关它的文章:

  • https://blog.golang.org/using-go-modules
  • < a href =“ https://github.com/golang/go/wiki/Modules” rel =“ nofollow noreferrer”> https://github.com/golang/go/wiki/Modules

    但是,在那之后,我仍然找不到像npmjs.com这样的地方可以找到可用的go模块。

  • 写回答
  • 好问题 提建议
  • 关注问题
  • 收藏
  • 邀请回答

3条回答 默认 最新

  • dplp5928 2019-04-11 09:52
    已采纳

    There is no central repository yet, but note that the module support is still experimental in Go 1.12. It will be enabled by default in Go 1.13 (scheduled for August 2019).

    Check out The Go Blog: Go Modules in 2019.

    For publicly-available modules, we intend to run a service we call a notary that follows the module index log, downloads new modules, and cryptographically signs statements of the form “module M at version V has file tree hash H.” The notary service will publish all these notarized hashes in a queryable, Certificate Transparency-style tamper-proof log, so that anyone can verify that the notary is behaving correctly. This log will serve as a public, global go.sum file that go get can use to authenticate modules when adding or updating dependencies.

    We are aiming to have the go command check notarized hashes for publicly-available modules not already in go.sum starting in Go 1.13.

    and

    Module Discovery

    Finally, we mentioned earlier that the module index will make it easier to build sites like godoc.org. Part of our work in 2019 will be a major revamp of godoc.org to make it more useful for developers who need to discover available modules and then decide whether to rely on a given module or not.

    Big Picture

    This diagram shows how module source code moves through the design in this post.

    enter image description here

    已采纳该答案
    评论
    解决 无用
    打赏 举报
  • doushi1900 2019-04-11 07:38

    There is no central repository for Go modules. As long as you follow the conventions for publishing Go packages (see PackagePublishing), the go tools will be able to fetch your package/module, no matter where you published it.

    In order to discover what is already out there in the Go universe, a good starting point is Awesome Go, a curated list of awesome Go packages/modules.

    评论
    解决 无用
    打赏 举报
  • dongtiandexue123456 2019-08-29 20:43

    https://search.gocenter.io can be used to search for Go modules, know more about popularity of a module version and even help module authors connect with their consumers. This is GA since end of January 2019 and globally available.

    评论
    解决 无用
    打赏 举报

相关推荐 更多相似问题