mirror of
https://github.com/boxpositron/absolute-vim.git
synced 2026-02-28 11:40:36 +00:00
feat(lualine.lua): add function IsMoltenActive to check if Molten plugin is active and display corresponding status line configuration
This commit is contained in:
@@ -89,6 +89,19 @@ function IsPoetvActive()
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function IsMoltenActive()
|
||||||
|
-- Check if molten is active
|
||||||
|
-- If molten is active, then return true
|
||||||
|
|
||||||
|
-- Check if vim.fn.MoltenStatusLineInit is a function
|
||||||
|
|
||||||
|
if vim.fn.exists("*MoltenStatusLineInit") == 1 then
|
||||||
|
return molten_status.initialized
|
||||||
|
else
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
-- configure lualine with modified theme
|
-- configure lualine with modified theme
|
||||||
lualine.setup({
|
lualine.setup({
|
||||||
options = {
|
options = {
|
||||||
@@ -101,11 +114,10 @@ lualine.setup({
|
|||||||
cond = IsFlutterToolsActive,
|
cond = IsFlutterToolsActive,
|
||||||
color = { fg = "#ff9e64" },
|
color = { fg = "#ff9e64" },
|
||||||
},
|
},
|
||||||
{
|
|
||||||
molten_status.initialized,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
molten_status.kernels,
|
molten_status.kernels,
|
||||||
|
cond = IsMoltenActive,
|
||||||
|
color = { fg = "#ff9e64" },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
GetPoetvStatusLine,
|
GetPoetvStatusLine,
|
||||||
|
|||||||
Reference in New Issue
Block a user