如何发布Go包 [英] How to publish a Go package
问题描述
我正在尝试发布我的Go包,以便在 doc搜索和搜索,并且可以使用去获取
。
然而,一份文件
a>我发现并没有清楚地告诉我如何获取生成和托管的文档,或者完全发布软件包。如何发布我的软件包?您已经完成了它。
为了发布Go软件包,您必须做的就是通过公共URL提供它。把它放在GitHub上,你已经发布了你的包。您可以查看 GoDoc 作为证明。搜索文档搜索可能需要更新,但是一旦您自行加载GoDoc,索引将自动发生。
至于Go搜索,只需点击页面顶部的添加软件包链接即可。
I am trying to publish my Go package so it is visible on doc search and go search, and can be installed with go get
.
However, the one document I found doesn't clearly tell me how to get the documentation generated and hosted, or to publish the package at all. How can I publish my package?
You already did it.
All you must do to "publish" a Go package is make it available via a public URL. By putting it on GitHub, you have already published your package. You can view the GoDoc as proof. It may take time for the doc search to update, but once you've loaded the GoDoc once on your own, the indexing will happen automatically.
As for Go search, just click the Add Packages link at the top of the page.
这篇关于如何发布Go包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!