zshr.vim : substitute and execute previous command.
script karma |
Rating 0/0,
Downloaded by 781 |
Comments, bugs, improvements
|
Vim wiki
|
created by |
omi taku |
|
script type |
utility |
|
description |
Substitute previous command string, and execute substituted command.
This plugin add ":R" command to your vim environment.
------------------------------------------------------------------------------
[command syntax]
:R {old}={new}
:R {old1}={new1} [{old2}={new2} {old3}={new3} ...]
------------------------------------------------------------------------------
[command example - 1]
1. Execute a command.
:%s/aaabbbccc/xxxyyyzzz/g
2. Execute ":R" command with replacement parameters.
:R a=m
(find "a" in last command, and replace "a" to "m".)
3. Vim editor execute this command.
:%s/mmmbbbccc/xxxyyyzzz/g
------------------------------------------------------------------------------
[command example - 2]
4. You want to use multiple replacement parameters,
you execute command this example.
:R a=m ccc=xyz bb=123
(find "a" in last command, and replace "a" to "m".
find "ccc" in last command, and replace "ccc" to "xyz".
find "bb" in last command, and replace "bb" to "123".)
|
|
install details |
1. Copy the zshr.vim script to
$HOME/vimfiles/plugin or $HOME/.vim/plugin directory.
Refer to ':help add-plugin', ':help add-global-plugin' and
':help runtimepath' for more details about Vim plugins.
2. Restart Vim.
3. "zshr.vim" plugin add ":R" command to your vim environment.
|
|
script versions (upload new version)
Click on the package to download.
ip used for rating: 142.132.191.50
|