Skip to content

mihasket/open-image.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

open-image.nvim is a simple keymap to open an image in Neovim.

Requirements

  • Neovim
  • Any image viewer application (Viewnoir, Eye Of Gnome, ...)

Usage

Place this code where you have your keybinding configuration. Replace viewnior with your image viewer of choice.

-- Keybinding to open the current image in buffer
vim.keymap.set(
  'n',
  '<leader>oi',
  function ()
    os.execute("viewnior " .. vim.api.nvim_buf_get_name(0) .. " &")
  end,
  { desc = '[O]pen [I]mage' }
)

About

a simple keymap to open an image in Neovim.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages