Runaway commands are not available after opening .vimrc for editing
My system is OS X 10.6 with MacVim 7.3 (GUI) and Vim 7.2 (on iTerm).
In MacVim, Fugitive doesn't work at all.
This is slightly different on Vim. I set up a mapping to open the file
nmap <silent> <leader>ev :e $MYVIMRC<CR>
Immediately after opening vim, all Fugitive commands are available, but after opening the file
using the above mapping, I cannot issue any Fugitive commands
. If I usually open the file
) everything is fine.
in the root directory) can be obtained from here .
What can I do to make it work?
source to share
The runaway functions are only available if the given file is part of a Git repository. Your file
is likely not under Git control, or if it is, you edited it with a symbolic path that Fugitive does not handle at the time of writing.
If your file is
indeed under version control, you can fix this by calling
on the canonical file path rather than through any symbolic links that will force Fugitive to find the
subdirectory and metadata correctly inside.