replace_operator.vim : Replace text from register with a motion
script karma |
Rating 15/6,
Downloaded by 696 |
Comments, bugs, improvements
|
Vim wiki
|
created by |
Tom Ryder |
|
script type |
utility |
|
description |
This plugin provides normal and visual mode mapping targets to replace the text bounded by a motion with the contents of a register, by default the unnamed register.
This allows you, for example, to select a set of lines and replace any other set of lines with it in one repeatable operation. The text you replace stacks up in the numbered registers as normal, if you do end up needing it back.
https://dev.sanctum.geek.nz/cgit/vim-replace-operator.git/
|
|
install details |
Drop plugin/replace_operator.vim in your ~/.vim/plugin directory, and autoload/replace_operator.vim in ~/.vim/autoload. Add doc/replace_operator.txt in ~/.vim/doc if you want the help file. Otherwise, use your favourite Vim plugin package manager.
The normal and visual mode mapping targets are both named
<Plug>(RepeatOperator). There are no default key mappings; you should define
some yourself in your vimrc. For example:
nmap <Leader>r <Plug>(ReplaceOperator)
xmap <Leader>r <Plug>(ReplaceOperator) |
|
script versions (upload new version)
Click on the package to download.
ip used for rating: 142.132.191.50
|