更新 Mercurial MQ 扩展中的提交消息
使用 hg qnew
和 hg qrefresh
创建并更新我想要应用于我的存储库的补丁后,但我在执行 hg 时编写的提交消息qnew 不太好,它没有引用 trac 中的票号,我想在其中谈谈我的提交解决的一些问题。
我该如何做类似 hg qrewritemycommitmessage
的事情。我检查了网站上的文档,但结果是空白。
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 do I do something like hg qrewritemycommitmessage
. I have examined the docs on the website and I have come up blank.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您只需执行
hg qrefresh -m "new commit message"
即可。You just do
hg qrefresh -m "new commit message"
.除了
kuy 建议的之外,您还可以使用
编辑当前消息。我发现这非常方便,因为我经常有多行提交消息,需要在补丁的生命周期内多次修改。事实上,我总是创建没有提交消息的补丁 - 只是
hg qnew foo
- 然后编辑提交消息。In addition to
suggested by kuy, you can also use
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.