On 26.02.2011 21:49, Barry Warsaw wrote: > On Feb 26, 2011, at 01:49 AM, Éric Araujo wrote: > >>You speak to my heart, sir. In your ~/.hgrc, under the section [ui], >>set “editor = path/to/mercurial/source/hgeditor” and enjoy your diffs. >>I use it and love it. > > Except it doesn't quite work the way I want it to (hg 1.6.3). It opens your > editor with two files, one is the commit message and the other is the diff. > (The script itself is a bit buggy too. ;) > > But it's a good clue, and I've modified the default hgeditor script to get > closer, and fix the bug I noticed. I basically append the diff to the > temporary log message file. It's still not right though because if the diff > lines aren't prepended with 'HG:', they end up in the commit message. Arg. > > Oh well, I can clearly hack a more complicated script together. It's such a > blindingly obvious improvement, it's too bad 'hg commit' doesn't DTRT by > default.
While I understand the usefulness of the diff feature, it is not useful to everyone, e.g. those using almost exclusively ``commit -m message``. Of course it would be nice if hg made it easier (a hgrc option, for example) to do this. BTW, I had not heard of hgeditor before, and wrote a small hg extension to do what you want (with HG: prefix :) before I saw that others had already replied with hgeditor. The extension had 10 lines of code. Georg _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com