Aborting commit due to empty commit message.
Could not amend commit after successfully picking 5e9159d9ce3a5c3c87a4fb7932fda4e53c7891db... 123 salt hashed passwords
This is most likely due to an empty commit message, or the pre-commit hook
failed. If the pre-commit hook failed, you may need to resolve the issue before
you are able to reword the commit.
You can amend the commit now, with
git commit --amend
Once you are satisfied with your changes, run
git rebase --continue
所以,只需修改信息:
git commit --amend -m "#123 salt hashed passwords"
--cleanup=<mode>
scissors
Same as whitespace, except that everything from (and including) the line
"# ------------------------ >8 ------------------------" is truncated if the message
is to be edited. "#" can be customized with core.commentChar.
$ git commit -m $'#228 update to a new version! margin of error is 33% | 33^*0.22;'
# commit message: #228 update to a new version! margin of error is 33% | 33^*0.22;
$ git commit -m $'docs!: new API reference for GPS horse navigation'
# commit message: docs!: new API reference for GPS horse navigation
如果没有使用$和',而是使用":
$ git commit -m "docs!: new API reference for GPS horse navigation"
bash: : unrecognized history modifier
如果与"一起使用并转义\ (\仍然存在,或者我做错了什么):
$ git commit -m "docs\!: new API reference for GPS horse navigation"
# commit message: docs\!: new API reference for GPS horse navigation