Closed MaxGyver83 closed 3 months ago
Hi,
First of all, $VIM
is an environment variable with special significance to vim. You can learn more about it by typing :help $VIM
from vim.
Also, some plugins do not work well with rc
due to its handling of double-quotes. I recently sent a patch to the vim-perl plugin to make it use single-quotes by default, which fixed things. Notice the use of shellxquote
, which is Vim's special variable to decide which type of quotes to use (also available via the :help
command).
First of all,
$VIM
is an environment variable with special significance to vim. You can learn more about it by typing:help $VIM
from vim.
Thank you! I didn't know this and the error message didn't point me there. I even didn't think this could matter because I set VIM
in bash and fish as well. The difference/problem is that rc
exports all variables automatically.
Also, some plugins do not work well with
rc
due to its handling of double-quotes. I recently sent a patch to the vim-perl plugin to make it use single-quotes by default, which fixed things. Notice the use ofshellxquote
, which is Vim's special variable to decide which type of quotes to use (also available via the:help
command).
Thank you for this hint! If I understand correctly, this only matters when I use rc
inside vim (set shell=/usr/local/bin/rc
)!?
If I understand correctly, this only matters when I use rc inside vim (set shell=/usr/local/bin/rc)!?
Indeed, of if, like me, you set SHELL=/bin/rc
in your environment. Vim will pick it up.
I have these lines in my
.rcrc
(for usage in aliases/functions):This breaks
vim
,nvim
and$VIM
.When I start
vim
, I get:When I start
nvim
, I get:Any ideas why this happens? Of course, I can remove these lines in my
.rcrc
but I want to understand this issue because otherwise I never know what's safe to do.