Better management for buffers (using Telescope), great to use in combination with a project plugin like (project.nvim / nvim-traveller.nvim)
showcase.mp4
- If you work with multiple projects, the buffer overview can get clogged up quickly using the builtin buffer view, but with this plugin it won't.
- It integrates with harpoon, so you don't need to consciously stay on top of adding / removing buffers from the list.
- Separates (project buffers / other buffers / term buffers)
- Tabbing through types of buffer overview
- Deleting buffers from the list
- Sort based on last time used
- Keep a maximum of buffers (20)
- Add to/Remove from harpoon list (optional)
- Custom mapping options
{ 'nvim-telescope/telescope.nvim', tag = '0.1.2' },
'ThePrimeagen/harpoon', -- optional
'norlock/nvim-traveller-buffers',
use 'nvim-telescope/telescope.nvim', tag = '0.1.2', -- (or whatever version)
use 'ThePrimeagen/harpoon', -- optional
use 'norlock/nvim-traveller-buffers',
vim.keymap.set('n', '<leader>b', require('nvim-traveller-buffers').buffers, {})
nnoremap <leader>b <cmd>lua require('nvim-traveller-buffers').buffers()<cr>
local traveller_buffers = require('nvim-traveller-buffers')
traveller_buffers.setup({
mappings = {
next_tab = "<Tab>",
previous_tab = "<S-Tab>",
harpoon_buffer = "<C-h>",
delete_buffer = "<C-d>",
preview_scrolling_up = "<C-b>",
preview_scrolling_down = "<C-f>",
delete_all = "<C-z>"
}
})
Key | Action |
---|---|
Tab | Next overview |
S-Tab | Previous overview |
C-d | Delete buffer |
C-z | Delete all (excl Harpoon) |
C-h | Toggle harpoon |
C-f | Preview scroll down |
C-b | Preview scroll up |