On 11/03/09 21:47, Harry Putnam wrote:

Shawn Walker<[email protected]>  writes:

What might cause ~/.vimrc to be ignored on vim start

It works fine on my system, but the file is owned by me, and it's not
a symlink.

It worked for me for a while too.  But now it doesn't. To test, I
moved the actual actual file into ~/ and as I showed in OP it belongs
to me.

ls -l .vimrc:
-rw-r--r-- 1 reader staff 8649 2009-03-11 15:43 .vimrc

But still it does not get sourced when I start vim on a file.

I use a symlinked vimrc, and it is always sourced correctly, but the details are different:

ls -l /root/.vimrc
lrwxrwxrwx 1 root root 20 2007-04-05 00:14 /root/.vimrc -> /home/tonymec/.vimrc

ls -l /home/tonymec/vimrc
-rw-r--r-- 1 tonymec users 12358 2009-03-05 00:09 /home/tonymec/.vimrc

Obviously, in this case both root and tonymec can both read and write the file (root because he can read & write anything, tonymec because he is the owner with rw- permissions), any other users can read it but not write it (because other users have r-- permissiopns regardless of their group).

Note that when issuing ":new ~/.vimrc" followed by some changes and finally ":x" in a Vim instance logged in as root, Vim "writes through" the link and transparently modifies ~tonymec/vimrc with no compunctions about it. That's what I want because I am both tonymec and AFAIK the only person knowing the root password on this box, and this symlink guarantees that I'll use the same vimrc regardless of whether I'm logged in as root or as tonymec.


Best regards,
Tony.
--
"God is big, so don't fuck with him."
_______________________________________________
opensolaris-discuss mailing list
[email protected]

Reply via email to