home: create 'modules/home' folder
Consolidating all modules under the same path, to clear out the top-level directory.
This commit is contained in:
parent
c856933803
commit
65a8f7c481
119 changed files with 2 additions and 2 deletions
61
modules/home/vim/plugin/settings/lualine.lua
Normal file
61
modules/home/vim/plugin/settings/lualine.lua
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
local lualine = require("lualine")
|
||||
local utils = require("ambroisie.utils")
|
||||
|
||||
local function list_spell_languages()
|
||||
if not vim.opt.spell:get() then
|
||||
return ""
|
||||
end
|
||||
|
||||
return table.concat(vim.opt.spelllang:get(), ", ")
|
||||
end
|
||||
|
||||
local function list_lsp_clients()
|
||||
local client_names = utils.list_lsp_clients()
|
||||
|
||||
if #client_names == 0 then
|
||||
return ""
|
||||
end
|
||||
|
||||
return "[ " .. table.concat(client_names, " ") .. " ]"
|
||||
end
|
||||
|
||||
lualine.setup({
|
||||
options = {
|
||||
icons_enabled = false,
|
||||
section_separators = "",
|
||||
component_separators = "|",
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {
|
||||
{ "mode" },
|
||||
},
|
||||
lualine_b = {
|
||||
{ "FugitiveHead" },
|
||||
{ "filename", symbols = { readonly = "🔒" } },
|
||||
},
|
||||
lualine_c = {
|
||||
{ list_spell_languages },
|
||||
{ "lsp_progress" },
|
||||
},
|
||||
lualine_x = {
|
||||
{ list_lsp_clients },
|
||||
{
|
||||
"diagnostics",
|
||||
-- Only use the diagnostics API
|
||||
sources = { "nvim_diagnostic" },
|
||||
},
|
||||
},
|
||||
lualine_y = {
|
||||
{ "fileformat" },
|
||||
{ "encoding" },
|
||||
{ "filetype" },
|
||||
},
|
||||
lualine_z = {
|
||||
"location",
|
||||
},
|
||||
},
|
||||
extensions = {
|
||||
"fugitive",
|
||||
"quickfix",
|
||||
},
|
||||
})
|
||||
Loading…
Add table
Add a link
Reference in a new issue