case insensitivity on hfsx

6 views
Skip to first unread message

Ewan

unread,
Jan 9, 2009, 6:21:47 PM1/9/09
to vim_mac
hi all -
If I save foo.txt in MacVim, then open FOO.TXT, I get foo.txt, even if
I'm working on an HFSX (case-sensitive HFS+) partition; I don't get
this in the vim that ships with OSX, nor do I get it if I recompile
vanilla vim from source. I do get it if I recompile MacVim from
source, but I'll be darned if I can find anything like this in
macvim.diff that I could disable. Needless to say, I don't *want* this
behaviour; so any tips on turning it off would be helpful.
thanks!
ewan

björn

unread,
Jan 10, 2009, 2:18:29 AM1/10/09
to vim...@googlegroups.com
Hi Ewan,

2009/1/10 Ewan

I don't have a case-sensitive volume available so I can't figure this
out myself, but I noticed these two defines in os_mac.h:

#define CASE_INSENSITIVE_FILENAME /* ignore case when comparing file names */
#define USE_FNAME_CASE /* make ":e os_Mac.c" open the file in its
original case, as "os_mac.c" */

Unless somebody else has a better answer than mine, I suggest you
undefine these, recompile and see if that makes a difference. Please
let us know what you find out.

Björn

Ewan

unread,
Jan 12, 2009, 10:18:15 PM1/12/09
to vim_mac

Yes, this solves the problem.

As far as I can tell USE_FNAME_CASE is not necessary even on case-
insensitive volumes; foo.txt opens as Foo.txt if Foo.txt is the
filename.

CASE_INSENSITIVE_FILENAME, on the other hand, is used in tab
completion (and maybe something else?); if we are on a case-
insensitive volume having CASE_INSENSITIVE_FILENAME undefined yields
incorrect tab-completion, conversely on a case sensitive volume.
Fixing this would evidently require rewriting the tab completion code.

ewan
Reply all
Reply to author
Forward
0 new messages