kkuchta/Vimbits — Issue #16: Feature: Tag dependent plugins and/or dependent vimbits
Author: darcyparker
Created: 2012-02-28 22:13:12+00:00
State: open

Some of the vimbits are dependent on vim plugins. It would be nice if there was a field to collect the dependent vimplugs (perhaps using URLs to their repository?)

As well, some of the vimbits would be best broken out into reusable vimbits that other vimbits could be dependent on. For example vimbits of functions.

And if you can see dependent vimbits, a 'where used' list would also be cool.

Example:
Potential vimbit #1
(Borrowed from http://technotales.wordpress.com/2010/03/31/preserve-a-vim-function-that-keeps-your-state/)

function! Preserve(command)
" Preparation: save last search, and cursor position.
let _s=@/
let l = line(".")
let c = col(".")
" Do the business:
execute a:command
" Clean up: restore previous search history, and cursor position
let @/=_s
call cursor(l, c)
endfunction

Potential vimbit #2
(Depends on potential vimbit #1 above)

"strip all trailing white space
nnoremap ws :call Preserve("%s/\\s\\+$//e")

Potential vimbit #3
(Depends on potential vimbit #1 above)

"reformat the indentation of the whole file
nnoremap = :call Preserve("normal gg=G")