From fffa30299a5ec3be759a4f0998c64b75ee9f8a1f Mon Sep 17 00:00:00 2001 From: Francesco Date: Mon, 12 May 2025 18:46:59 +0200 Subject: [PATCH] improvements --- .config/nvim/init.lua | 4 ++++ .config/nvim/lazy-lock.json | 10 ---------- .config/nvim/lua/plugins/bufferline.lua | 16 ++++++++++++++++ README.md | 5 ++++- 4 files changed, 24 insertions(+), 11 deletions(-) delete mode 100644 .config/nvim/lazy-lock.json create mode 100644 .config/nvim/lua/plugins/bufferline.lua diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua index bc29047..dcea49d 100644 --- a/.config/nvim/init.lua +++ b/.config/nvim/init.lua @@ -17,3 +17,7 @@ vim.keymap.set("n", "F", function() require("conform").format({ async = true }) end, {}) +vim.keymap.set("n", "n", ":BufferLineCycleNext", {}) +vim.keymap.set("n", "b", ":BufferLineCyclePrev", {}) +vim.keymap.set("n", "q", ":bd", {}) + diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json deleted file mode 100644 index 7115ba5..0000000 --- a/.config/nvim/lazy-lock.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "blink.cmp": { "branch": "main", "commit": "4f38ce99a472932d5776337f08f7a8180f1f571a" }, - "catppuccin": { "branch": "main", "commit": "1bf070129c0b6f77cc23f6a2212dcdc868308c52" }, - "conform.nvim": { "branch": "master", "commit": "374aaf384e2e841607b8e2fe63fa3ad01d111c91" }, - "lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" }, - "nvim-lspconfig": { "branch": "master", "commit": "61e5109c8cf24807e4ae29813a3a82b31821dd45" }, - "nvim-treesitter": { "branch": "master", "commit": "28d480e0624b259095e56f353ec911f9f2a0f404" }, - "plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" }, - "telescope.nvim": { "branch": "master", "commit": "a0bbec21143c7bc5f8bb02e0005fa0b982edc026" } -} diff --git a/.config/nvim/lua/plugins/bufferline.lua b/.config/nvim/lua/plugins/bufferline.lua new file mode 100644 index 0000000..c838b4f --- /dev/null +++ b/.config/nvim/lua/plugins/bufferline.lua @@ -0,0 +1,16 @@ +return { + "akinsho/bufferline.nvim", + version = "*", + dependencies = "nvim-tree/nvim-web-devicons", + opts = { + options = { + always_show_bufferline = true, + separator_style = "slant", + closable = false, + show_buffer_icons = true, + show_buffer_close_icons = false, + enforce_regular_tabs = false, + } + } +} + diff --git a/README.md b/README.md index 9678f36..a48eee9 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,10 @@ The leader key is the `Space`. `ff` - Find files `fg` - Live grep -`fb` - Telescope buffers +`fb` - Show buffers `fh` - Help tags `F` - Format file (only works with C files) +`q` - Quit buffer +`n` - Next buffer +`b` - Previous buffer