为什么 git 流程功能检查被弃用?我应该改用什么?

Why is git flow feature checkout being deprecated? What should I be using instead?

我正在 运行宁 git 版本 2.3.6git flow 版本 1.8.0 当我 运行 命令像 git flow feature checkout <branch> 我收到消息:

The command 'git flow feature checkout/co' will be deprecated per version 2.0.0

有谁知道为什么这会被弃用and/or我应该改用什么?

根据您的问题 (1.8.0) 中指定的版本号,您指的是 https://github.com/petervanderdoes/gitflow (as opposed to https://github.com/nvie/gitflow,在撰写此答案时,其最新版本是 0.4.1)。克隆该 repo 并检查其日志后,运行

git log --grep=feature --grep=deprecated --all-match

我只找到了 one relevant commit,这并没有促使弃用 git flow feature checkout

但是,GitHub 上的回购问题跟踪器中的 issue #128 包含有关计划弃用 git flow feature checkout 的讨论。这是维护者评论的相关段落:

My thoughts

Checkout

  • With bash/zsh completion this command seems irrelevant but if you don't use completion it could be helpful.
  • I suggest dropping this command in a future release and add a warning per v1.8.0 that the command will be dropped on a future version (2.0?)