1. Read the output of a vim command (ex mode).
Say for example to list all the loaded plugins in vim
:redir end
To paste from register q just type:
"qp
The output is in vim now.
2. Read the output of a external command in vim
Say for example, i want to get the list of all processes in linux in vim
:read !ps -ef
and the processlist is now in the vim buffer.
Say for example to list all the loaded plugins in vim
:redir @q
:scriptnames
The output is now saved into q register.
Say for example, i want to get the list of all processes in linux in vim
:read !ps -ef
and the processlist is now in the vim buffer.
No comments:
Post a Comment