1.下载
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
2.配置vimrc
set nocompatible " be iMproved,required filetype off " required " set the runtime path to include Vundle and initialize set rtp+=~/.vim/bundle/Vundle.vim call vundle#begin() " alternatively,pass a path where Vundle should install plugins "call vundle#begin('~/some/path/here') " let Vundle manage Vundle,required Plugin 'VundleVim/Vundle.vim' " The following are examples of different formats supported. " Keep Plugin commands between vundle#begin/end. " plugin on GitHub repo Plugin 'tpope/vim-fugitive' " plugin from http://vim-scripts.org/vim/scripts.html " Plugin 'L9' " Git plugin not hosted on GitHub Plugin 'git://git.wincent.com/command-t.git' " Install L9 and avoid a Naming conflict if you've already installed a " different version somewhere else. " Plugin 'ascenator/L9',{'name': 'newL9'} " All of your Plugins must be added before the following line Plugin 'mzlogin/vim-markdown-toc' call vundle#end() " required filetype plugin indent on " required " To ignore plugin indent changes,instead use: "filetype plugin on " " Brief help " :PluginList - lists configured plugins " :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate " :PluginSearch foo - searches for foo; append `!` to refresh local cache " :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal " " see :h vundle for more details or wiki for FAQ " Put your non-Plugin stuff after this line
3.重新加载vim,进行安装
4.安装vim-markdown-toc
只需要将
Plugin 'mzlogin/vim-markdown-toc'
放到配置上面
然后执行
:PluginInstall
5.使用vim-markdown-toc
:GenTocgFM Generate table of contents in GFM link style. This command is suitable for Markdown files in GitHub repositories,like README.md,and Markdown files for GitBook. :GenTocRedcarpet Generate table of contents in Redcarpet link style. This command is suitable for Jekyll or anywhere else use Redcarpet as its Markdown parser. :GenTocgitLab Generate table of contents in GitLab link style. This command is suitable for GitLab repository and wiki. :GenTocmarked Generate table of contents for iamcco/markdown-preview.vim which use Marked markdown parser.
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。