最初的需求
我的需求很简单,必须tab等于四个空格。
编辑,vim /etc/vimrc
编辑内容如下,
set nu
set tabstop=4
set autoindent
set mouse=a
set smartindent
set hlsearch
set showmatch
set foldenable
vim go setting
Goal:实现golang代码的语法高亮。
Environment:Centos
Step
- git clone
cd ~/.vim/bundle
$ git clone https://github.com/Valloric/YouCompleteMe.git
$ cd YouCompleteMe
$ python install.py
If you don't install cmake,you will be prompted to install cmake.
- install cmake
wget https://cmake.org/files/v3.10/cmake-3.10.1.tar.gz
tar cmake-3.10.1.tar.gz
cd cmake-3.10.1
./bootstrap
make && make install
ubuntu vim 安装插件管理
1 vim-addon-manager
1.1 安装 vim-addon-manager
1. sudo apt-get install vim-addon-manager
2. sudo apt-get install vim-scripts
3. sudo apt-get install vim-doc
1.2 vim-addons 常见命令
- 使用 vim-addons install taglist(或各种插件)
2 vim 支持 markdown
git clone https://github.com/plasticboy/vim-markdown.git
cd vim-markdown
sudo make install
vim-addon-manager install markdown