Skip to content

Redirect the output of Vim or external command to scratch buffer, in LUA

License

Notifications You must be signed in to change notification settings

sbulav/nredir.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nredir.nvim

A nredir Redirect the output of a Vim or external command into a scratch buffer, in LUA. It's basically an implementation of Romainl's Redir, written for learn purposes in Lua.

Installing

NOTE: This plugin requires Neovim 0.5 versions

Plug 'sbulav/nredir.nvim'

Usage

Show full output of command :buffers in scratch window:

:Nredir buffers

Show full output of command !ls -la in scratch window:

:Nredir !ls -la
  • Pressing enter will maximize scratch window
  • Pressing q will automatically close the window
  • Pressing w will enable/disable wrap :h wrap

You can also create a mapping to open command-line window and substitute Nredir:

nnoremap <leader>R :Nredir <c-f>A

Screenshot

nredir.nvim

About

Redirect the output of Vim or external command to scratch buffer, in LUA

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published