dotvim/.vim/functions.vim

14 lines
414 B
VimL
Raw Normal View History

2015-04-18 05:42:29 +00:00
augroup vimrc
autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
augroup END
2015-03-09 06:04:43 +00:00
2015-02-18 09:25:46 +00:00
function! s:unalign() range
for l:line in range(a:firstline, a:lastline)
let l:text = getline(l:line)
let l:subst = substitute(l:text, '\(\S\+\)\s\{2,}', '\1 ', 'g')
call setline(l:line, l:subst)
endfor
endfunction
command! -range UnAlign <line1>,<line2>call s:unalign()