How can I specify a multiline commit message for mercurial on the command line?
hg commit -m \"* add foo\\n* fix bar\"
does not work. The log
From Windows cmd, do this command for a multiline commit.
hg commit -l con
This allows you to enter a multiple line commit message straight from the command line. To end your message, hit Enter, and on a line by itself hit Ctrl + Z and Enter again.
Why? The -l
option to hg commit
says to read the commit message from a file, and con
specifies that the file is actually the console.