On 29/12/13 11:48, egarrulo wrote:
> On my Linux distro there are these system-wide initialization files:
>
> /etc/vim/gvimrc
> /etc/vim/vimrc
> /etc/vim/vimrc.tiny
> /usr/share/vim/gvimrc
> /usr/share/vim/vimrc
> /usr/share/vim/vimrc.tiny
>
> Does GVim load any of them?
>
> :echo $MYVIMRC
>
> returns ~/.vimrc, while
>
> :version
>
> returns
>
>     system vimrc file: "$VIM/vimrc"
>       user vimrc file: "$HOME/.vimrc"
>   2nd user vimrc file: "~/.vim/vimrc"
>        user exrc file: "$HOME/.exrc"
>    system gvimrc file: "$VIM/gvimrc"
>      user gvimrc file: "$HOME/.gvimrc"
> 2nd user gvimrc file: "~/.vim/gvimrc"
>      system menu file: "$VIMRUNTIME/menu.vim"
>    fall-back for $VIM: "/home/egarrulo/bin/vim/vim-7.4.280/share/vim"
>
> and
>
> :echo $VIM
>
> returns:
>
> /home/egarrulo/bin/vim/vim-7.4.280/share/vim
>
> and no .vimrc is there.  Thus, GVim shouldn't be loading any of the
> above system-wide init files, but it seems it does.
>
> Any idea?  Thanks.
>
1. Try "ls -l" on some of these files (in subfolders of /etc and of 
/usr/share) to see if any of them is a soft link. (Seeing if it's a hard 
link is less obvious). Or maybe /home/egarrulo or 
/home/egarrulo/bin/vim/vim-7.4.280/share are soft links?
2. Maybe there is another Vim (later in the $PATH) on your system? What 
does the bash commands
	type -a vim
	type -a gvim
return? (I'm saying bash because in bash "type" is a builtin command, 
which reports even about aliases; I don't know how to get the same 
results with other shells.)
Here too, apply "ls -l" to any answer until you've resolved all 
softlinks there might be (for instance, gvim may be a link to vim).
The system-wide vimrc for that copy of Vim, sourced before the user's 
vimrc, is $VIM/vimrc — with whatever $VIM may be when that user runs 
Vim. You seem to find that $VIM is $HOME/vim/vim-7.4.280/share/vim, for 
another user it would probably not be a subfolder of _your_ $HOME.
Also, I wonder why you have a "vim-7.4.280" link in that path. Do you 
change that at every patchlevel? Also, where did you get that "280" 
from? The current patchlevel is only 7.4.131.
For the Vim that I compile for my home computer, I use Vim's defaults, 
namely:
	$VIM = /usr/local/share/vim
	$VIMRUNTIME = $VIM/vim74 (at version 7.4)
	The (Huge) vim executable is in /usr/local/bin
	The gvim executable is a soft link
	        /usr/local/share/bin/gvim -> ./vim
	In addition I have a Tiny vim executable at /usr/local/bin/vi
This way, my custom runtime files (not from the Vim distribution) at 
/usr/local/share/vim/vimfiles/ (system-wide) and, of course, at 
$HOME/.vim/ (single-user) will remain even after the release of Vim 7.5 
or 8.0.
Best regards,
Tony.
-- 
WHERE CAN THE MATTER BE
	Oh, dear, where can the matter be
	When it's converted to energy?
	There is a slight loss of parity.
	Johnny's so long at the fair.
-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Sunday, December 29, 2013
Subscribe to:
Post Comments (Atom)
 
No comments:
Post a Comment