Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- "" Copy/Paste/Cut
- if has('unnamedplus')
- set clipboard=unnamed,unnamedplus
- endif
- set foldmethod=indent
- nmap o o<Esc>
- nmap O O<Esc>
- nmap ;;' :set opfunc=WrapWithQuotes<CR>g@
- vmap ;;' <Esc>`<i'<Esc>`>a'<Esc>
- imap ;;' ''<Left>
- nmap ;;" :set opfunc=WrapWithDoubleQuotes<CR>g@
- vmap ;;" <Esc>`<i"<Esc>`>a"<Esc>
- imap ;;" ""<Left>
- nmap ;;( :set opfunc=WrapWithParentheses<CR>g@
- vmap ;;( <Esc>`<i(<Esc>`>a)<Esc>
- imap ;;( ()<Left>
- nmap ;;{ :set opfunc=WrapWithCurlyBrackets<CR>g@
- vmap ;;{ <Esc>`<i{<Esc>`>a}<Esc>
- imap ;;{ {}<Left>
- nmap ;;[ :set opfunc=WrapWithSquareBrackets<CR>g@
- vmap ;;[ <Esc>`<i[<Esc>`>a]<Esc>
- imap ;;[ []<Left>
- nmap ;;< :set opfunc=WrapWithTriangleBrackets<CR>g@
- vmap ;;< <Esc>`<i<<Esc>`>a><Esc>
- imap ;;< <><left>
- nmap ,, :set opfunc=WrapWithParentheses<CR>g@
- function! WrapWithQuotes(type)
- normal! `[v`]`<i'`>la'
- endfunction
- function! WrapWithDoubleQuotes(type)
- normal! `[v`]`<i"`>la"
- endfunction
- function! WrapWithParentheses(type)
- normal! `[v`]`<i(`>la)
- endfunction
- function! WrapWithSquareBrackets(type)
- normal! `[v`]`<i[`>la]
- endfunction
- function! WrapWithCurlyBrackets(type)
- normal! `[v`]`<i{`>la}
- endfunction
- function! WrapWithTriangleBrackets(type)
- normal! `[v`]`<i<`>la>
- endfunction
Advertisement
Add Comment
Please, Sign In to add comment