From 69e7706b49aa048b567bf7bb76572be5953b1ca5 Mon Sep 17 00:00:00 2001 From: pika Date: Sat, 22 Mar 2025 03:06:11 +0100 Subject: [PATCH] add: buffline to know the filenames --- lua/pika/plugins/ui.lua | 98 ++++++++++++++++++++--------------------- 1 file changed, 49 insertions(+), 49 deletions(-) diff --git a/lua/pika/plugins/ui.lua b/lua/pika/plugins/ui.lua index 0a02416..a09c5e6 100644 --- a/lua/pika/plugins/ui.lua +++ b/lua/pika/plugins/ui.lua @@ -2,55 +2,55 @@ return { -- ╭───────────────────────────────────────╮ -- │ bufferline - for mistakes and stuff.. │ -- ╰───────────────────────────────────────╯ - -- { - -- "akinsho/bufferline.nvim", - -- dependencies = { "echasnovski/mini.icons" }, - -- version = "*", - -- opts = { - -- options = { - -- diagnostics = "nvim_lsp", - -- diagnostics_update_on_event = true, -- use nvim's diagnostic handler - -- diagnostics_indicator = function(count, level) - -- local icon = level:match("error") and " " or " " - -- return " " .. icon .. count - -- end, - -- offsets = { { filetype = "neo-tree", text = "File Explorer", highlight = "Directory" } }, - -- -- ─< style >─────────────────────────────────────────────────────────────────────────── - -- indicator = { - -- icon = "▎", -- this should be omitted if indicator style is not 'icon' - -- style = "icon", - -- }, - -- move_wraps_at_ends = true, -- whether or not the move command "wraps" at the first or last position - -- separator_style = "slope", - -- -- ─< icons >─────────────────────────────────────────────────────────────────────────── - -- modified_icon = "󱞇", - -- left_trunc_marker = "󰬩", - -- right_trunc_marker = "󰬫", - -- themable = true, -- allows highlight groups to be overriden i.e. sets highlights as default - -- close_icon = "󱄊", - -- buffer_close_icon = "󱄊", - -- show_buffer_icons = true, -- disable filetype icons for buffers - -- show_buffer_close_icons = true, - -- show_close_icon = true, - -- show_tab_indicators = true, - -- hover = { - -- enabled = true, - -- delay = 80, - -- reveal = { "close" }, - -- hide = { "nvim_lsp" }, - -- }, - -- -- You can set buffer_mode to "list" or "tabbed" based on your preference. - -- buffer_mode = "list", - -- color_icons = true, -- whether or not to add the filetype icon highlights - -- }, - -- }, - -- config = function(_, opts) - -- require("bufferline").setup(opts) - -- -- Remap the tab key for buffer navigation (you can adjust the keys as needed) - -- vim.keymap.set("n", "", "BufferLineCycleNext") - -- vim.keymap.set("n", "", "BufferLineCyclePrev") - -- end, - -- }, + { + "akinsho/bufferline.nvim", + dependencies = { "echasnovski/mini.icons" }, + version = "*", + opts = { + options = { + diagnostics = "nvim_lsp", + diagnostics_update_on_event = true, -- use nvim's diagnostic handler + diagnostics_indicator = function(count, level) + local icon = level:match("error") and " " or " " + return " " .. icon .. count + end, + offsets = { { filetype = "neo-tree", text = "File Explorer", highlight = "Directory" } }, + -- ─< style >─────────────────────────────────────────────────────────────────────────── + indicator = { + icon = "▎", -- this should be omitted if indicator style is not 'icon' + style = "icon", + }, + move_wraps_at_ends = true, -- whether or not the move command "wraps" at the first or last position + separator_style = "slope", + -- ─< icons >─────────────────────────────────────────────────────────────────────────── + modified_icon = "󱞇", + left_trunc_marker = "󰬩", + right_trunc_marker = "󰬫", + themable = true, -- allows highlight groups to be overriden i.e. sets highlights as default + close_icon = "󱄊", + buffer_close_icon = "󱄊", + show_buffer_icons = true, -- disable filetype icons for buffers + show_buffer_close_icons = true, + show_close_icon = true, + show_tab_indicators = true, + hover = { + enabled = true, + delay = 80, + reveal = { "close" }, + hide = { "nvim_lsp" }, + }, + -- You can set buffer_mode to "list" or "tabbed" based on your preference. + buffer_mode = "list", + color_icons = true, -- whether or not to add the filetype icon highlights + }, + }, + config = function(_, opts) + require("bufferline").setup(opts) + -- Remap the tab key for buffer navigation (you can adjust the keys as needed) + vim.keymap.set("n", "", "BufferLineCycleNext") + vim.keymap.set("n", "", "BufferLineCyclePrev") + end, + }, -- ╭───────────────────────────────────╮ -- │ cmdline - for nice command inputs │