如何为git flow release finish
提供一个真实的消息?
这是我的尝试和输出结果:
> git flow release finish -m 'Release 0.0.4 - Fixing a bug' 0.0.4
flags:FATAL the available getopt does not support spaces in options
我唯一能使其工作的方法是在消息中不使用任何空格。
如何为git flow release finish
提供一个真实的消息?
这是我的尝试和输出结果:
> git flow release finish -m 'Release 0.0.4 - Fixing a bug' 0.0.4
flags:FATAL the available getopt does not support spaces in options
我有同样的问题,但是收到了不同的错误信息:
$ git flow release finish -m 'Release 0.0.4 - Fixing a bug' 0.0.4
fatal: too many params
Tagging failed. Please run finish again to retry.
$ echo 'Release 0.0.4 - Fixing a bug' > .git/MY_TAGMSG
$ git config core.editor "mv .git/MY_TAGMSG"
$ git flow release finish 0.0.4
$ git config --unset core.editor
尝试使用命令"git flow version"。
如果你得到了类似于0.X的东西,那么让它正常工作的简单方法是使用git-flow的新CLI。
你可以在这里找到它:
https://github.com/petervanderdoes/gitflow/wiki
所以对于我(在MacOSX上),解决方案是:
sudo brew unlink git-flow
sudo brew install git-flow-avh
您是否拥有最新的gitflow?似乎您的版本不支持get-opt选项中的空格。您可以尝试以下解决方法:
安装最新的gitflow:
$ git clone git://github.com/nvie/gitflow.git
$ cd gitflow
$ git svn clone -r HEAD http://shflags.googlecode.com/svn/trunk/source/1.0 shFlags
$ sudo make install
从Homebrew安装gnu-opt:
$ brew install gnu-getopt
$ echo 'export FLAGS_GETOPT_CMD="$(brew --prefix gnu-getopt)/bin/getopt"' >> ~/.bashrc
$ . ~/.bashrc # 注意点号然后是~/.bashrc或者只需启动一个新终端
$ echo $FLAGS_GETOPT_CMD
应返回以"bin/getopt"结尾的内容,然后尝试您的命令...
git svn
是一个有效的命令吗?当我尝试运行它时,出现了错误。 - Gregapt-get install git-svn
或者适用于你的操作系统的等价命令。 - Michael