Easy Go vendoring

git freeze will submodule or subtree all git-package Go imports from ./... into vendor/.

Status

Build Status

Install

 go get github.com/gomatic/git-freeze

Usage

If your GOBIN is also in your PATH, git-freeze will be accessible as:

 git freeze

Help

 Usage:
        -branch string
                    Git branch/commit to submodule/subtree. (defaults to the parent's branch)
        -dry-run
                    Just print the command but do not run it.
        -force
                    Force.
        -list
                    Only list the imports that can be frozen.
        -notests
                    Do not freeze test-imports.
        -subtree
                    Use a subtree instead of a submodule.
        -transitive
                    Traverse transitive imports, i.e. vendor/
        -verbose
                    More output.

Note

git freeze -transitive will traverse ./..., so running it multiple times will continually freeze transitive dependencies. But, ideally, you do not want to use -transitive since transitive dependencies should be vendored/frozen by the package maintainer.



Easy Go vendoring

git freeze 将子模块或子树所有git-package Go从。/ … 导入到 vendor /

Status

建立状态

安装

 go get github.com/gomatic/git-freeze

用法

如果您的 GOBIN 也在您的 PATH 中,则 git-freeze 将可访问:

 git freeze

帮助

 Usage:
        -branch string
                    Git branch/commit to submodule/subtree. (defaults to the parent's branch)
        -dry-run
                    Just print the command but do not run it.
        -force
                    Force.
        -list
                    Only list the imports that can be frozen.
        -notests
                    Do not freeze test-imports.
        -subtree
                    Use a subtree instead of a submodule.
        -transitive
                    Traverse transitive imports, i.e. vendor/
        -verbose
                    More output.

注意

git freeze -transitive 将遍历。/ … ,因此多次运行它将不断地冻结传递依赖关系。但是,理想情况下,您不希望使用 -transitive ,因为传递性依赖关系应由软件包维护者负责/冻结。




相关问题推荐