Again on EOLs
Ted Pavlic
ted at tedpavlic.com
Mon Jun 9 13:20:06 CDT 2008
>> I notice that on my OS/X system, multi-line MQ messages default to Mac
>> format even though I have
I should have been more precise. If I start with:
hg qnew -m "Message" Blah
and then later do:
hg qrefresh -e
Then the single-line file I see is Mac formatted (probably because it
has nothing at the end of its single line).
If MQ would always terminate single-line messages with a line feed, that
would fix the problem.
> I just have that in my .vimrc. But you could do something like
> (untested):
>
> autocmd BufEnter /tmp/hgeditor\..* setl ff=unix
Good point -- I used this:
autocmd BufEnter /tmp/hgeditor.* setl ff=unix
That is, the "*" is a glob, not a regexp.
A "problem" with this approach is that even unmodified messages
immediately LOOK modified to vim. That is, I can't exit the editor
unless I ":wq" or ":q!". Of course, in most cases, this wouldn't be a
problem (or even noticeable).
--Ted
--
Ted Pavlic <ted at tedpavlic.com>
More information about the Mercurial
mailing list