4 ms·
> The comment character in Git commit messages can be a problem when you insist on prepending your commits with some "id" and the id starts with `#` https://gi
by pwdisswordfishz 2y ago
> The comment character in Git commit messages can be a problem when you insist on prepending your commits with some "id" and the id starts with `#`
https://git-scm.com/docs/git-commit#Documentation/git-commit.txt---cleanupltmodegt https://git-scm.com/docs/git-commit#Documentation/git-commit...
- keybored 2y agoSee "commit cleanup". There’s surprising layers to this. That the reporter in that thread says that git-commit will “happily” accept `#` in commit messages is half-true: it will accept it if you don’t edit the message since the `default` cleanup (that you linked to) will not remove comments if the message is given through things like `-m` and not an editing session. So `git commit -m'#something' is fine. But then try to do rebase and cherry-pick and whatever else later, maybe get a merge commit message with a commented "conflicted" files. Well it can get confusing.