我刚刚完成了Vim的全新安装,在这个场合,我为我的VIM配置添加了一些新的插件.问题是,现在,当我对文件进行第一次更改时,VIM会阻塞并且我的一个CPU达到100%负载.此外,当我正在编辑文件时,这种情况时有发生.这在以前的配置中从未发生过.我怎么能找到什么插件杀死我的CPU?
当我用命令-T搜索某个文件时,它常常很难找到它,因为我不在正确的目录中,所以我必须更改目录.
是否可以设置命令-T将首先在书签Nerdtree或其他地方的目录中搜索?
我可以将目录更改为/但是此搜索范围非常大的文件.当我将dir更改为我的主目录并且我正在寻找一些普通的东西时,.bashrc我会找到位于.wine目录下的相当多的文件.
在99%的时间里,我需要搜索我积极使用的项目目录中的文件.我可以在某些首选项中设置这些目录吗?
有没有办法从vimscript中编写的vim插件中调用C++共享库函数?
假设有一个hello_world.so,它有一个函数hello_world().每当vim用户使用特定的键绑定时,我想调用此函数.
我已经为Eclipse找到了几个Vim插件,但是有些计算机在Eclipse上存在性能问题.
所以,我想知道Netbeans IDE是否有任何插件,它在较弱的计算机上运行更顺畅.
如果重要,我有兴趣支持Java,Python和C++.(关于其中一个受欢迎的任何答案).
我有一台运行Windows 7的桌面和一台运行Mountain Lion的Macbook Pro.我分别使用gVim和MacVim.我喜欢让我的插件和设置在机器之间保持同步,所以我将它们存储在我的Google云端硬盘中,我可以随时将它们从那里拉出来.
在我的Mac上,我的主文件夹中只有一个.gvimrc文件和一个.vim文件夹,Vim正确加载了我所有的插件和设置.
但是,在我的Windows计算机上,Vim会从我的主文件夹中的.ggvimrc文件正确加载设置.但如果我将插件存储在"home.vim\plugin"中,Vim将不会加载它们.
要在我的Windows机器上运行插件/主题,我需要将它们放在"C:\ Program Files(x86)\ Vim\vimfiles\plugin"中
我希望能够将所有内容存储在任一台机器上的"home.vim"文件夹中,并使其正常工作.
那么有什么方法可以在我的Windows机器上进行设置吗?
谢谢!
如何覆盖 neovim lua 配置文件中的某些配色方案值?我正在尝试使用 .lua 而不是 .vim。以前在我的 init.vim 文件中,我用它来覆盖一些设置,我也想为 init.lua 文件启用这些设置。我怎样才能做到这一点?
highlight ColorColumn ctermbg=0 guibg=lightgrey
highlight Normal ctermfg=white ctermbg=black
autocmd ColorScheme * highlight CursorLineNr cterm=bold term=bold gui=bold
Run Code Online (Sandbox Code Playgroud)
我按照博客http://web.archive.org/web/20120731003342/http://www.charlietanksley.net/philtex/sane-vim-plugin-management上的说明安装了Vundle
但是当:BundleInstall我试图运行时,我得到一个VIM错误
E492: Not an editor command: BundleInstall
Run Code Online (Sandbox Code Playgroud)
这是我的 tree ~/.vim
/home/max/.vim
??? bundle
??? vundle
??? autoload
? ??? vundle
? ? ??? config.vim
? ? ??? installer.vim
? ? ??? scripts.vim
? ??? vundle.vim
??? doc
? ??? vundle.txt
??? LICENSE-MIT.txt
??? README.md
??? test
??? files
? ??? test.erl
??? minirc.vim
??? vimrc
Run Code Online (Sandbox Code Playgroud)
另外,当启动VIM时,我会得到一些E492像这样的东西
Error detected while processing /home/max/.vimrc:
line 6:
E117: Unknown function: vundle#rc
line 10:
E492: Not an editor …Run Code Online (Sandbox Code Playgroud) 我正在尝试在我的Macvim上安装Vundle.我按照以下链接获取Vundle.我还配置了我的.vimrc文件.但是当我尝试PluginInstall时,我收到以下错误.
E492: Not an editor command: PluginInstall
Run Code Online (Sandbox Code Playgroud)
我的.vimrc包含以下内容:
1 set nocompatible "https://stackoverflow.com/questions/5845557/in-a-vimrc-is-set-nocc
ompatible-completely-useless
2
3 " https://github.com/gmarik/Vundle.vim
4 filetype off " required
5
6 " set the runtime path to include Vundle and initialize
7 set rtp+=~/.vim/bundle/Vundle.vim
8 call vundle#begin()
9 " alternatively, pass a path where Vundle should install plugins
10 "call vundle#begin('~/some/path/here')
11
12 " let Vundle manage Vundle, required
13 Plugin 'gmarik/Vundle.vim'
14
15 " All of your Plugins must be added before the following …Run Code Online (Sandbox Code Playgroud) 我在CentOS 5上有Vim 7(增强版),它附带了所有常用的Vim插件/脚本.
$ find /usr/share/vim/vim70/ -name \*python\*
/usr/share/vim/vim70/syntax/python.vim
/usr/share/vim/vim70/ftplugin/python.vim
/usr/share/vim/vim70/indent/python.vim
/usr/share/vim/vim70/autoload/pythoncomplete.vim
Run Code Online (Sandbox Code Playgroud)
我认为当打开以.py(vim file.py)结尾的文件时,它会自动加载这些插件,但我不确定是这种情况.我想要的是:
按下TAB并接收四个空格.套房,条件等的自动缩进下一行
我通过在.vimrc文件中明确设置tabstop,shiftwidth等来实现这一点.这不是上面的Python文件的用途吗?为什么我要把这些东西放在我身上.vimrc呢?我如何从Vim插件中获取这些功能呢?
目前的.vimrc:
syntax on
set hls
set expandtab
set textwidth=0
set tabstop=4
set softtabstop=4
set shiftwidth=4
set autoindent
set backspace=indent,eol,start
set incsearch
set ignorecase
set ruler
set wildmenu
set smarttab
filetype indent on
filetype on
filetype plugin on
Run Code Online (Sandbox Code Playgroud) vim中的默认对齐方式(使用"=")将我的代码对齐为:
void my_loooong_function (int arg1,
int arg2,
int arg3
)
Run Code Online (Sandbox Code Playgroud)
但是,我希望与从同一行开始的所有参数一致,如:
void my_loooong_function (int arg1,
int arg2,
int arg3
)
Run Code Online (Sandbox Code Playgroud)
如何才能做到这一点?