shadmansaleh 846e5bdabf fix(extension): fix some extension showing a section in whole line
For now use a dummy component to lualine_x on extensions that only define
lualine_a. This will let the renderer know right sections do exist.

closes #73
2021-10-01 19:54:57 +06:00

24 lines
366 B
Lua

-- Copyright (c) 2020-2021 hoob3rt
-- MIT license, see LICENSE for more details.
local function get_short_cwd()
return vim.fn.fnamemodify(vim.fn.getcwd(), ':~')
end
local empty = {
function()
return ' '
end,
padding = 0,
}
local M = {}
M.sections = {
lualine_a = { get_short_cwd },
lualine_x = { empty },
}
M.filetypes = { 'nerdtree' }
return M