Skip to content

Instantly share code, notes, and snippets.

@colindresj
colindresj / toggle_width.vim
Last active February 23, 2018 01:13
nerdtree_plugin/toggle_width
" put this script in ~/.vim/nerdtree_plugin/
call NERDTreeAddKeyMap({
\ 'key': 'w',
\ 'callback': 'NERDTreeToggleWidth',
\ 'quickhelpText': 'Toggle window width' })
function! NERDTreeToggleWidth()
let l:maxi = 0
for l:z in range(1, line("$"))