开发者

How to prevent merge from falling back to normal merge strategy when a fast-forward merge is not possible?

The git merge command has an option to perform开发者_如何学Go fast-forward merge, but this is not what I want, because if it can't do a fast-forward merge, it uses the normal merge.

Is there a git command which only performs a fast-forward merge (from the tracked remote branch) and does nothing if the fast-forward merge is not possible?


From the git-merge man page:

--ff-only

Refuse to merge and exit with a non-zero status unless the current HEAD is already up-to-date or the merge can be resolved as a fast-forward.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜