mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-22 00:49:01 +02:00
add: update custom nvim tree, remove root folder
This commit is contained in:
parent
e5a9b6e638
commit
fc175ae9ad
5 changed files with 177 additions and 163 deletions
|
@ -6,6 +6,12 @@ end
|
|||
local icons = require("user.icons")
|
||||
local use_icons = true
|
||||
|
||||
-- get folder name from current directory
|
||||
local _get_folder_name = function()
|
||||
local str = vim.fn.fnamemodify(vim.fn.getcwd(), ":t")
|
||||
return " " .. str:lower():gsub("^%l", string.upper) .. " "
|
||||
end
|
||||
|
||||
local function diagnostics_indicator(num, _, diagnostics, _)
|
||||
local result = {}
|
||||
local symbols = {
|
||||
|
@ -58,14 +64,14 @@ bufferline.setup({
|
|||
offsets = {
|
||||
{
|
||||
filetype = "NvimTree",
|
||||
text = "Explorer",
|
||||
text = _get_folder_name(),
|
||||
highlight = "Directory",
|
||||
text_align = "left",
|
||||
padding = 1,
|
||||
},
|
||||
{
|
||||
filetype = "neo-tree",
|
||||
text = "Explorer",
|
||||
text = _get_folder_name(),
|
||||
highlight = "Directory",
|
||||
text_align = "left",
|
||||
padding = 1,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue