Arch 2025 rice. Also contains a newly inspired neovim config.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
1.8 KiB

2 weeks ago
1 week ago
2 weeks ago
  1. return {
  2. 'romgrk/barbar.nvim',
  3. dependencies = {
  4. 'lewis6991/gitsigns.nvim', -- OPTIONAL: for git status
  5. 'nvim-tree/nvim-web-devicons', -- OPTIONAL: for file icons
  6. },
  7. init = function()
  8. vim.g.barbar_auto_setup = false
  9. local map = vim.api.nvim_set_keymap
  10. local opts = { noremap = true, silent = true }
  11. -- Move to previous/next
  12. map('n', '<leader>,', '<Cmd>BufferPrevious<CR>', opts)
  13. map('n', '<leader>.', '<Cmd>BufferNext<CR>', opts)
  14. -- Re-order to previous/next
  15. map('n', '<leader><', '<Cmd>BufferMovePrevious<CR>', opts)
  16. map('n', '<leader>>', '<Cmd>BufferMoveNext<CR>', opts)
  17. -- Goto buffer in position...
  18. map('n', '<leader>1', '<Cmd>BufferGoto 1<CR>', opts)
  19. map('n', '<leader>2', '<Cmd>BufferGoto 2<CR>', opts)
  20. map('n', '<leader>3', '<Cmd>BufferGoto 3<CR>', opts)
  21. map('n', '<leader>4', '<Cmd>BufferGoto 4<CR>', opts)
  22. map('n', '<leader>5', '<Cmd>BufferGoto 5<CR>', opts)
  23. map('n', '<leader>6', '<Cmd>BufferGoto 6<CR>', opts)
  24. map('n', '<leader>7', '<Cmd>BufferGoto 7<CR>', opts)
  25. map('n', '<leader>8', '<Cmd>BufferGoto 8<CR>', opts)
  26. map('n', '<leader>9', '<Cmd>BufferGoto 9<CR>', opts)
  27. map('n', '<leader>0', '<Cmd>BufferLast<CR>', opts)
  28. -- Pin/unpin buffer
  29. map('n', '<leader>p', '<Cmd>BufferPin<CR>', opts)
  30. map('n', '<leader>i', '<Cmd>BufferPick<CR>', opts)
  31. -- Close buffer
  32. map('n', '<leader>c', '<Cmd>w|BufferClose<CR>', opts)
  33. map('n', '<leader>q', '<Cmd>BufferClose!<CR>', opts)
  34. end,
  35. opts = {
  36. -- lazy.nvim will automatically call setup for you. put your options here, anything missing will use the default:
  37. -- animation = true,
  38. -- insert_at_start = true,
  39. -- …etc.
  40. },
  41. version = '^1.9.0', -- optional: only update when a new 1.x version is released
  42. }