Tony Mechelynck wrote:
On 19/03/11 04:35, Rostyslaw Lewyckyj wrote:
Win 7 x 64 with VIM 7.3 installed as by default from download.
into C:\Program Files (x86)\Vim\vim73.

1) Where are the system wide vimrc and gvimrc? i.e. those that get
sourced
for any execution of vim or gvim. NOT the vimrc_example.vim or
gvimrc_example.vim,

Normally it is $VIM/vimrc and $VIM/gvimrc with no initial dot or
underscore in the filename but it can be changed at compile-time. See
under "system vimrc file" and "system gvimrc file" near the middle of
the output of the :version command. Of course if you do it in a console
version of Vim there will be no "system gvimrc file".

unless those are the defaults sourced unless other customized ones are
provided by the administrator.
In the latter case where would these be placed/stored.

The system vimrc/gvimrc _are_ the ones which an admin would use (and in
practice, I've only seen them used misguidedly, by admins who thought
that "they knew better than me what was good for me").

2) Where does an arbitrary user place his private vimrc & gvimrc?

Normally on Windows it is $HOME/_vimrc (if you don't know where $HOME
is, type ":echo $HOME" without the quotes in a running Vim) or, failing
that, $VIM/_vimrc. In both cases, Vim looks for .vimrc if _vimrc is not
found. Similarly, at GUI startup gvim looks for $HOME/_gvimrc,
$HOME/.gvimrc, $VIM/_gvimrc and $VIM/.gvimrc in turn, and uses the first
one found.

Here too these defaults can be changed at compile-time, and the actual
values used are mentioned near the middle of the :version text; but
there the fact that .vimrc or .gvimrc is looked for if _vimrc or _gvimrc
is not found is not mentioned explicitly.

3) When an arbitrary user starts a vim/gvim instance is his vimrc/gvimrc
sourced instead of
or in addition to the systemwide vimrc gvimrc?

In addition to, and in gvim the gvimrc is sourced in addition to the vimrc.


Where (other than the actual vim code) is any of this described in
detail?

See ":help startup" (which has, at the appropriate point, a link to
":help gui-init") for all the juicy (or gory, depending on point of
view) details.


HTH,
Tony.
Sorry to bother you, but I must be doing something wrong.
I fired up Gvim and echoed $HOME and $VIM.
I copied the example_vimrc.vim and example_gvimrc.vim files
to $VIM\vimrc and $VIM\gvimrc
Then I tried to create private $HOME\_vimrc and $HOME_gvimrc files

As soon as I put the line  'set  number' into either of those files
I lose the ability to visually  select text via <SHIFT> + keyboard
line-up and line-down. Now these key presses cause skips of
approximately 20 lines up or down.

What I'd like is to put :
   set number
   set so=999
into _vimrc
and
   hi Visual guibg=#bbbbbb
into _gvimrc

Without the _vimrc and _gvimrc files, when I edit a file,
and enter the set and hi commands manually from the keyboard
everything appears to be functioning as expected.

What am I doing wrong?
advance thanks
--
Rostyk

--
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

Reply via email to