我如何在 Capistrano 3.7.1 中调用 git,因为 strategy.git 不再起作用?

How can I call git in Capistrano 3.7.1, since strategy.git doesn't work anymore?

我已经从 3.6.1 -> 3.7.1 更新了 capistrano gem。

我的一项任务中有以下代码: strategy.git "push #{fetch(:git_remote, 'origin')} #{tag_name}"

现在随着更改并需要 SCM::GIT 插件,策略变量不再存在。

现在如何访问 git command/object?什么才算马上做?

所有 strategy.git 所做的就是执行 git 命令。所以这是等价的:

execute :git, "push #{fetch(:git_remote, 'origin')} #{tag_name}"