sponsor Vim development Vim logo go to HTTPS page Vim Book Ad

unimpaired.vim : Pairs of handy bracket mappings

 script karma  Rating 238/92, Downloaded by 3934    Comments, bugs, improvements  Vim wiki

created by
Tim Pope
script type
Much of unimpaired.vim was extracted from my vimrc when I noticed a pattern: complementary pairs of mappings.  They fall into three categories.

There are mappings which are simply short normal mode aliases for commonly used ex commands. ]q is :cnext. [q is :cprevious. ]a is :next. [b is :bprevious.  See the documentation for the full set of 16 mappings and mnemonics.  All of them take a count.

There are linewise mappings. [<Space> and ]<Space> add newlines before and after the cursor line. [e and ]e exchange the current line with the one above or below it.

There are mappings for encoding and decoding. [x and ]x encode and decode XML (and HTML). [u and ]u encode and decode URLs. [y and ]y do C String style escaping.

Oh, and there's also [f and ]f to go to the previous/next file in the directory, and [n and ]n to go between SCM conflict markers.

install details
Unzip in ~/.vim (~\vimfiles on Windows). Use :helptags ~/.vim/doc to enable :help.

Rating scripts is only available on the HTTPS page

script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
unimpaired.zip 1.2 2013-01-14 7.0 Tim Pope Add repeat.vim support.
Add [t and ]t for :tprev and :tnext.
Add [n and ]n for jumping between conflict markers.
Add [<C-Q> and ]<C-Q> for :cpfile and :cnfile.
Add [<C-L> and ]<C-L> for :lpfile and :lnfile.
Deprecate [o and ]o in favor of new maps [f and ]f.
Improve robustness of [f and ]f.
Improve robustness of [e and ]e.
Fix unescaping of "\a" and "\$".
Work around `unnamedplus' in clipboard.
Expose API for custom encoding algorithms.
unimpaired.zip 1.1 2010-03-07 7.0 Tim Pope Add <Plug> aliases for all mappings.
Skip swap files with ]o and [o.
Accept a count with [e and ]e.
unimpaired.zip 1.0 2010-01-29 6.0 Tim Pope Initial upload
ip used for rating:

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
SourceForge.net Logo