问题描述
我已经做过一个单行提交消息了一段时间,但它没有提供有关提交的全部信息.
I have been doing a oneline commit message for some time now but it doesn't give the entire information on the commit.
git commit -m "message"
我曾经使用过git Gui工具,它可以选择执行多行提交消息.标题为一,详细信息为一.我们如何从命令行中做到这一点?
I once used git Gui tool and it had option to do multiline commit message. One in header and one in detail.How do we do it from the command line?
有人可以解释提交错误修复和新更改的任何好的做法吗?我通常在提交消息的开头写"NEW:"或"FIX",我想知道你们是怎么做到的?
And can some one explain any good practice to commit bug fix and new changes? I normally write "NEW:" or "FIX" at start of the commit message, i would like to know how you guys do this?
推荐答案
您可以从命令行执行:
git commit -m 'First line
Second line
Third line'
或者,您可以通过执行以下操作让git触发您的编辑器
Alternatively, you can just let git trigger your editor by doing
git commit
这篇关于如何在git中执行多行提交消息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!