Go 项目的依赖 URL 列表
List of dependency URLs of a Go project
我想获取 Go 项目中所有依赖项的 tarball URLs(或类似文件)列表。我试图用 'go list dependency' 来实现这一点,但我认为不可能获得依赖项的来源 URL。我怎样才能得到 URL?
对于当前目录,您可以通过以下方式获取导入:
go list -f '{{join .Imports "\n"}}' .
我想获取 Go 项目中所有依赖项的 tarball URLs(或类似文件)列表。我试图用 'go list dependency' 来实现这一点,但我认为不可能获得依赖项的来源 URL。我怎样才能得到 URL?
对于当前目录,您可以通过以下方式获取导入:
go list -f '{{join .Imports "\n"}}' .