我的$HOME/vimfiles
中有我的Vim配置。但是,有时我想尝试修改配置而不会弄乱我的标准设置。是否可以让vim查看启动文件的不同vimfiles
目录?
最简单的选择可能是将$HOME
设置为不同的值并运行Vim,但这会干扰其他软件(我在Windows上,所以它不像Unix用户那么糟糕,但我使用Msys对我的一些工作,并设置$HOME
会影响其他东西。
答案 0 :(得分:1)
-u {vimrc} Use the commands in the file {vimrc} for initializations. All the
other initializations are skipped. Use this to edit a special kind
of files. It can also be used to skip all initializations by giving
the name "NONE". See ":help initialization" within vim for more
details.
e.g。我有一个非常基本的vimrc文件,保存为~/base.vimrc
和别名:
kent$ alias bvi
bvi='vim -u ~/base.vimrc'