mirror of
https://github.com/nmasur/dotfiles
synced 2024-11-10 04:02:55 +00:00
27 lines
664 B
Nix
27 lines
664 B
Nix
{ pkgs, ... }:
|
|
{
|
|
|
|
# Shows buffers in a VSCode-style tab layout
|
|
|
|
plugins = [
|
|
pkgs.vimPlugins.bufferline-nvim
|
|
pkgs.vimPlugins.vim-bbye # Better closing of buffers
|
|
];
|
|
setup.bufferline = {
|
|
options = {
|
|
diagnostics = "nvim_lsp";
|
|
always_show_bufferline = false;
|
|
separator_style = "slant";
|
|
offsets = [ { filetype = "NvimTree"; } ];
|
|
};
|
|
};
|
|
lua = ''
|
|
-- Move buffers
|
|
vim.keymap.set("n", "L", ":BufferLineCycleNext<CR>", { silent = true })
|
|
vim.keymap.set("n", "H", ":BufferLineCyclePrev<CR>", { silent = true })
|
|
|
|
-- Kill buffer
|
|
vim.keymap.set("n", "<Leader>x", " :Bdelete<CR>", { silent = true })
|
|
'';
|
|
}
|