Skip to content

Commit

Permalink
feat: udpate bufferline separator
Browse files Browse the repository at this point in the history
  • Loading branch information
s3igo committed Mar 31, 2024
1 parent 2367a21 commit 7cb308d
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions neovim/config/plugins/editor/heirline.lua
Original file line number Diff line number Diff line change
Expand Up @@ -262,23 +262,23 @@ local tabline = (function()
local filename = {
provider = function(self)
local name = self.filename
return #name == 0 and '[No Name] ' or vim.fn.fnamemodify(name, ':t') .. ' '
return #name == 0 and ' [No Name] ' or ' ' .. vim.fn.fnamemodify(name, ':t') .. ' '
end,
hl = function(self) return { fg = (self.is_active or self.is_visible) and colors.blue or colors.dark_gray } end,
}

local flag = {
{
condition = function(self) return vim.api.nvim_get_option_value('modified', { buf = self.bufnr }) end,
provider = '[+]',
provider = '[+] ',
hl = { fg = colors.orange },
},
{
condition = function(self)
return not vim.api.nvim_get_option_value('modifiable', { buf = self.bufnr })
or vim.api.nvim_get_option_value('readonly', { buf = self.bufnr })
end,
provider = '[-]',
provider = '[-] ',
hl = { fg = colors.blue },
},
}
Expand All @@ -289,9 +289,7 @@ local tabline = (function()
flag,
}

local separator = { provider = ' ' }

return utils.make_buflist(file, separator, separator, function() return buflist_cache end, false)
return utils.make_buflist(file, nil, nil, function() return buflist_cache end, false)
end)()

require('heirline').setup({
Expand Down

0 comments on commit 7cb308d

Please sign in to comment.