user1649972 user1649972 - 2 years ago 135
Git Question

Vimrc not updating

I am trying to setup vim to wrap my git commits to 72 characters but I am having trouble doing so. When I edit ":e $myvimrc" and add the settings to wrap the text it doesn't seem to work. I tried to open the vimrc file directly form my program files to check that the changes I have made had indeed been saved, but they are not showing in the file.

Strange thing is that when I open the vimrc file in vim to edit it the changes I made are still there, they just don't seem to be saving to the actual file.

I have tried to edit the vimrc directly as well but it wont allow me to save in that location. Hopefully im just doing something silly and if I am I apologies, very fresh to git and vim. Thanks in advance

Answer Source

It is recommended to place your personal Vim configuration in your user's home directory (on Windows, typically C:\Users\<yourname>; or use :e $HOME/_vimrc inside Vim).

If your ~/.vimrc file currently resides in Vim's installation directory, under C:\Program Files (i.e. $VIM/_vimrc), then you're experiencing the effects of the Windows File System Redirector, redirecting non-admin writes to Program Files into a virtual store (cp. UAC Virtualization and how it affects your Installers.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download