最初的需求
我的需求很簡(jiǎn)單旱易,必須tab等于四個(gè)空格偏瓤。
編輯份乒,vim /etc/vimrc
編輯內(nèi)容如下姆泻,
set nu
set tabstop=4
set autoindent
set mouse=a
set smartindent
set hlsearch
set showmatch
set foldenable
vim go setting
Goal:實(shí)現(xiàn)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