相关疑难解决方法(0)

从命令行向'git commit -m'添加换行符

我从命令行使用Git,并尝试在提交消息(使用git commit -m "")中添加换行符而不进入Vim.

这可能吗?

git bash shell

693
推荐指数
14
解决办法
24万
查看次数

git commit -m 多行

如何使用 -m 在 git 提交中生成多行注释

$ git commit -m "This change is for blah"
$ git commit -m "This change is for blah\nAnd also for this blah"
Run Code Online (Sandbox Code Playgroud)

第二行,\n不产生多行注释

我使用的是 Mac 终端,不确定这是否重要。

git

2
推荐指数
1
解决办法
3881
查看次数

标签 统计

git ×2

bash ×1

shell ×1