After using hg qnew
and hg qrefresh
to create and update a patch that I want to apply to my repository, but the commit message that I wrote when I did hg qnew
was not very good, it did not reference the ticket number from trac, and I would like to say something in it about some of the issues that my commit addresses.
How d开发者_StackOverflowo I do something like hg qrewritemycommitmessage
. I have examined the docs on the website and I have come up blank.
You just do hg qrefresh -m "new commit message"
.
In addition to
$ hg qrefresh -m "new message"
suggested by kuy, you can also use
$ hg qrefresh -e
to edit the current message. I find that very handy since I often have multi-line commit messages that I need to revise many times over the lifetime of a patch. Infact, I always create my patches with no commit message — just hg qnew foo
— and then edit the commit message as I go along.
精彩评论