Installing Vim's YCM

Source: Internet
Author: User
Tags git clone

Environment CentOS 6.7 Vim 7.3

Installing Vundle

Vundle (Vim bundle) is a vim plug-in manager. It is to integrate GIT operations, the user needs to do is to go to GitHub to find the name of the plugin they want to install, update and uninstall can have vundle to complete.

Github:https://github.com/gmarik/vundle.vim

git clone https://github.com/gmarik/vundle.git. Vim/bundle/vundle

Then create a new file named. VIMRC in the user's home directory, and the contents of my file are as follows:

Set Nu

Set Fileencoding=utf-8

Set Fileencodings=utf-8,gb18030,gb2312,gbk,big5

Set ts=4

Set Expandtab

Set Autoindent

Set nocompatible

Set Syntax=on

FileType off "required!

Set rtp+=~/.vim/bundle/vundle/

Call VUNDLE#RC ()

"Let Vundle manage Vundle

"Required!  

Bundle ' Gmarik/vundle '

Bundle ' Mattn/emmet-vim '

Bundle ' Auto-pairs '

Bundle ' Php-doc '

Bundle ' Phpdoc-script-pdocs '

Let G:user_emmet_expandabbr_key = ' <Tab> '

Let g:user_emmet_settings = {' Indentation ': '}

FileType plugin indent on "required!

The installation of this vundle is complete.

To use Vundle, you can add the Bundle ' Bundle_name ' to the _VIMRC created above. Then turn on vim and run the Vundle related command to execute:

Install plugin:: Bundleinstall update plugin:: bundleinstall! Uninstall plugin:: Bundleclean

As for what plug-ins can be added, you can find them in vim-scripts.org. In addition, you can add git-managed repo (including GitHub, not on GitHub, and local repo)

If the installation is complete, you can configure it in the ~/.VIMRC.

Add the following code to the line:

Let g:ycm_global_ycm_extra_conf = ' ~/.vim/bundle/youcompleteme/cpp/ycm/.ycm_extra_conf.py ' "Configure the default ycm_extra_conf.py Nnoremap <leader>jd:ycmcompleter gotodefinitionelsedeclaration<cr> "Press, JD will jump to define let G:ycm_confirm_extra_ Conf=0 "Open vim no longer asks whether to load ycm_extra_conf.py configuration let G:ycm_collect_identifiers_from_tag_files = 1" Use Ctags generated tags file

Installing Vim's YCM

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.