Ⅰ. 插件描述
Vim GAP template engine syntax highlighting, indentation and syntax checkerⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'petrushka/vim-gap'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'petrushka/vim-gap'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'petrushka/vim-gap'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/petrushka/vim-gap
Ⅳ. 文档说明
== SYNOPSIS:
Vim-gap is a vim plugin for GAP support. Vim-gap supports syntax highlighting, indentation, completion, folding and syntax checker for GAP in Vim editor.
== Installation
I recommend to use Pathogen (http://www.vim.org/scripts/script.php?script_id=2332) to organize Vim plugins. In this case you should do following:
cd ~/.vim/bundle
git clone git://github.com/petRUShka/vim-gap.git
If you want to enable gap syntax checker then you should install Syntastic plugin (https://github.com/scrooloose/syntastic). Installation of this plugin is the same.
== Some functions and macros
- ToggleCommentGAP -- toggle comment, add or remove "## " (mapped on F12)
- <F4> -- macro to add word under cursor to `local' list
- GAPlocal -- add whole `local' declaration to current function (mapped on <F5>)
Then the completion mechanism <CTRL>-p is extended to complete all GAP variable names. For word completion, fall back to list of GAP global variable names: after loading your favorite packages in GAP say
for w in NamesGVars() do AppendTo("~/.vim/GAPWORDS",w,"n"); od;
For vim version >= 6.0 folding is switched on and indentation switched on.