vimdb模拟单个数据库
vimdb 是一个用来模拟单个数据库的 Vim 插件。
增加你精确查找vim的元素的速度以及对vim的一些了解:keys(keybindings)、可选项、命令。vimdb是vim默认的items,一个在你的vimrc,一个在插件里。vimdb的插件只要检测到你在用pathogen-like安装,就会生效。例如,每个插件都有自己的目录,在~ /.vim/bundle/(见下面的目录结构变化)。在mac下测试的 vim> = 7.2。只有在ruby1.9.x下才会起作用。
安装
$ gem install vimdb
基本查询不同的vim items的基本用法:
# List keys with Ctrl $ vimdb keys C- +---------------+------+---------------------+------------------------------------------ | key | mode | from | desc | +---------------+------+---------------------+-----------------------------------------| | 0 C-d | i | default | delete all indent in the current line | | | i | default | cursor past end of fil | | | n | default | 1 same as "G" | | | i | default | cursor to start of file | | | n | default | 1 same as "gg" | | | n | default | 1 same as "b" | ... 262 rows in set # List options that contain word 'window' in any field $ vimdb options window -a +----------------+--------+----------------------------------------------------+ | name | alias | desc | +----------------+--------+----------------------------------------------------+ | autochdir | acd | change directory to the file in the current window | | bufhidden | bh | what to do when buffer is no longer in window | | cedit | | key used to open the command-line window | | cmdwinheight | cwh | height of the command-line window | | cscopequickfix | csqf | use quickfix window for cscope results | | cursorbind | crb | move cursor in window as it moves in other windows | | diff | | use diff mode for the current window | | equalalways | ea | windows are automatically made the same size | | guiheadroom | ghr | GUI: pixels room for window decorations | | helpheight | hh | minimum height of a new help window | | icon | | let Vim set the text of the window icon | ... 30 rows in set # Search for commands from pathogen plugin $ vimdb commands pathogen -f=from +----------+-------+---------------------+-----------------------------------------------------+ | name | alias | from | desc | +----------+-------+---------------------+-----------------------------------------------------+ | Helptags | | pathogen.vim plugin | :call pathogen#helptags() | | Ve | | pathogen.vim plugin | :execute s:find(,'edit',,0) | | Vedit | | pathogen.vim plugin | :execute s:find(,'edit',,0) | | Vopen | | pathogen.vim plugin | :execute s:find(,'edit',,1) | | Vpedit | | pathogen.vim plugin | :execute s:find(,'pedit',,1) | | Vread | | pathogen.vim plugin | :execute s:find(,'read',,1) | | Vsplit | | pathogen.vim plugin | :execute s:find(,'split',,1) | | Vtabedit | | pathogen.vim plugin | :execute s:find(,'tabedit',,1) | | Vvsplit | | pathogen.vim plugin | :execute s:find(,'vsplit',,1) | +----------+-------+---------------------+-----------------------------------------------------+ 9 rows in set # Info about how a vim item is made $ vimdb info keys Created using index.txt and :map # For a list of all commands $ vimdb
评论