How do I add multi-line messages using
git commit -a -m "..."
The answer from this similar question appears to work (judging by the upvotes and acceptance), but it seems a bit cumbersome1.
The git documentation reads:
-m <msg>
--message=<msg>
Use the given <msg> as the commit message. If multiple -m options are given, their values are concatenated as separate paragraphs.
So, would it be advisable to just use a new -m
for each new line of the message? Or do "paragraphs" add additional line spacings?
It would be nice if future versions of the command would allow us to just add \n
between sentences, to denote line breaks.
1 The linked answer basically advises to use a message template file, and direct git to use the file via git commit -t <template_file>