Nvim is now running Lazy as its plugin Manager.
New keymaps Nvim.leap instead of flash
This commit is contained in:
@@ -1,73 +1,194 @@
|
||||
local M = {}
|
||||
local colors = {
|
||||
bg = "none",
|
||||
fg = "#ebdbb2",
|
||||
yellow = "#fabd2f",
|
||||
cyan = "#8ec07c",
|
||||
darkblue = "#458588",
|
||||
green = "#b8bb26",
|
||||
orange = "#fe8019",
|
||||
violet = "#d3869b",
|
||||
magenta = "#d3869b",
|
||||
blue = "#83a598",
|
||||
red = "#fb4934",
|
||||
grey = "#504945",
|
||||
black = "#282828",
|
||||
white = "#fbf1c7",
|
||||
darkgrey = "#3c3836",
|
||||
lightgrey = "#665c54",
|
||||
}
|
||||
|
||||
M.theme = function()
|
||||
local colors = {
|
||||
darkgray = "#16161d",
|
||||
gray = "#727169",
|
||||
innerbg = nil,
|
||||
outerbg = "#16161D",
|
||||
normal = "#7e9cd8",
|
||||
insert = "#98bb6c",
|
||||
visual = "#ffa066",
|
||||
replace = "#e46876",
|
||||
command = "#e6c384",
|
||||
}
|
||||
return {
|
||||
inactive = {
|
||||
a = { fg = colors.gray, bg = colors.outerbg, gui = "bold" },
|
||||
b = { fg = colors.gray, bg = colors.outerbg },
|
||||
c = { fg = colors.gray, bg = colors.innerbg },
|
||||
},
|
||||
visual = {
|
||||
a = { fg = colors.darkgray, bg = colors.visual, gui = "bold" },
|
||||
b = { fg = colors.gray, bg = colors.outerbg },
|
||||
c = { fg = colors.gray, bg = colors.innerbg },
|
||||
},
|
||||
replace = {
|
||||
a = { fg = colors.darkgray, bg = colors.replace, gui = "bold" },
|
||||
b = { fg = colors.gray, bg = colors.outerbg },
|
||||
c = { fg = colors.gray, bg = colors.innerbg },
|
||||
},
|
||||
normal = {
|
||||
a = { fg = colors.darkgray, bg = colors.normal, gui = "bold" },
|
||||
b = { fg = colors.gray, bg = colors.outerbg },
|
||||
c = { fg = colors.gray, bg = colors.innerbg },
|
||||
},
|
||||
insert = {
|
||||
a = { fg = colors.darkgray, bg = colors.insert, gui = "bold" },
|
||||
b = { fg = colors.gray, bg = colors.outerbg },
|
||||
c = { fg = colors.gray, bg = colors.innerbg },
|
||||
},
|
||||
command = {
|
||||
a = { fg = colors.darkgray, bg = colors.command, gui = "bold" },
|
||||
b = { fg = colors.gray, bg = colors.outerbg },
|
||||
c = { fg = colors.gray, bg = colors.innerbg },
|
||||
},
|
||||
}
|
||||
end
|
||||
local theme = {
|
||||
normal = {
|
||||
a = { fg = colors.black, bg = colors.blue, gui = "bold" },
|
||||
b = { fg = colors.blue, bg = colors.grey },
|
||||
c = { fg = colors.white, bg = colors.darkgrey },
|
||||
x = { fg = colors.white, bg = colors.darkgrey },
|
||||
y = { fg = colors.blue, bg = colors.grey },
|
||||
z = { fg = colors.black, bg = colors.blue, gui = "bold" },
|
||||
},
|
||||
insert = {
|
||||
a = { fg = colors.black, bg = colors.green, gui = "bold" },
|
||||
b = { fg = colors.green, bg = colors.grey },
|
||||
c = { fg = colors.white, bg = colors.darkgrey },
|
||||
x = { fg = colors.white, bg = colors.darkgrey },
|
||||
y = { fg = colors.green, bg = colors.grey },
|
||||
z = { fg = colors.black, bg = colors.green, gui = "bold" },
|
||||
},
|
||||
visual = {
|
||||
a = { fg = colors.black, bg = colors.magenta, gui = "bold" },
|
||||
b = { fg = colors.magenta, bg = colors.grey },
|
||||
c = { fg = colors.white, bg = colors.darkgrey },
|
||||
x = { fg = colors.white, bg = colors.darkgrey },
|
||||
y = { fg = colors.magenta, bg = colors.grey },
|
||||
z = { fg = colors.black, bg = colors.magenta, gui = "bold" },
|
||||
},
|
||||
replace = {
|
||||
a = { fg = colors.black, bg = colors.red, gui = "bold" },
|
||||
b = { fg = colors.red, bg = colors.grey },
|
||||
c = { fg = colors.white, bg = colors.darkgrey },
|
||||
x = { fg = colors.white, bg = colors.darkgrey },
|
||||
y = { fg = colors.red, bg = colors.grey },
|
||||
z = { fg = colors.black, bg = colors.red, gui = "bold" },
|
||||
},
|
||||
command = {
|
||||
a = { fg = colors.black, bg = colors.yellow, gui = "bold" },
|
||||
b = { fg = colors.yellow, bg = colors.grey },
|
||||
c = { fg = colors.white, bg = colors.darkgrey },
|
||||
x = { fg = colors.white, bg = colors.darkgrey },
|
||||
y = { fg = colors.yellow, bg = colors.grey },
|
||||
z = { fg = colors.black, bg = colors.yellow, gui = "bold" },
|
||||
},
|
||||
inactive = {
|
||||
a = { fg = colors.white, bg = colors.darkgrey },
|
||||
b = { fg = colors.white, bg = colors.darkgrey },
|
||||
c = { fg = colors.white, bg = colors.darkgrey },
|
||||
},
|
||||
}
|
||||
|
||||
require('lualine').setup {
|
||||
return {
|
||||
"nvim-lualine/lualine.nvim",
|
||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||
event = "VeryLazy",
|
||||
opts = {
|
||||
options = {
|
||||
icons_enabled = true,
|
||||
theme = M.theme(), -- Apply the custom theme
|
||||
component_separators = { left = '', right = '' },
|
||||
section_separators = { left = '', right = '' },
|
||||
disabled_filetypes = {
|
||||
statusline = {},
|
||||
winbar = {},
|
||||
},
|
||||
ignore_focus = {},
|
||||
always_divide_middle = true,
|
||||
always_show_tabline = true,
|
||||
globalstatus = false,
|
||||
refresh = {
|
||||
statusline = 100,
|
||||
tabline = 100,
|
||||
winbar = 100,
|
||||
icons_enabled = true,
|
||||
theme = theme,
|
||||
component_separators = { left = "", right = "" },
|
||||
section_separators = { left = "", right = "" },
|
||||
disabled_filetypes = {
|
||||
statusline = {},
|
||||
winbar = {},
|
||||
},
|
||||
ignore_focus = {},
|
||||
always_divide_middle = true,
|
||||
globalstatus = true,
|
||||
refresh = {
|
||||
statusline = 100,
|
||||
tabline = 100,
|
||||
winbar = 100,
|
||||
},
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {
|
||||
{
|
||||
"mode",
|
||||
fmt = function(str)
|
||||
local mode_map = {
|
||||
["NORMAL"] = "N",
|
||||
["INSERT"] = "I",
|
||||
["VISUAL"] = "V",
|
||||
["V-LINE"] = "VL",
|
||||
["V-BLOCK"] = "VB",
|
||||
["COMMAND"] = "C",
|
||||
["REPLACE"] = "R",
|
||||
["TERMINAL"] = "T"
|
||||
}
|
||||
return mode_map[str] or str
|
||||
end,
|
||||
separator = { right = "" }
|
||||
}
|
||||
},
|
||||
lualine_b = {
|
||||
{
|
||||
"branch",
|
||||
icon = "",
|
||||
separator = { right = "" }
|
||||
},
|
||||
{
|
||||
"diff",
|
||||
symbols = { added = " ", modified = " ", removed = " " },
|
||||
separator = { right = "" }
|
||||
},
|
||||
{
|
||||
"diagnostics",
|
||||
symbols = { error = " ", warn = " ", info = " ", hint = " " },
|
||||
separator = { right = "" }
|
||||
}
|
||||
},
|
||||
lualine_c = {
|
||||
{
|
||||
"filename",
|
||||
path = 1,
|
||||
shorting_target = 40,
|
||||
symbols = { modified = "", readonly = "", unnamed = "" }
|
||||
}
|
||||
},
|
||||
lualine_x = {
|
||||
{
|
||||
function()
|
||||
local clients = vim.lsp.get_clients()
|
||||
if next(clients) == nil then
|
||||
return ""
|
||||
end
|
||||
local client_names = {}
|
||||
for _, client in pairs(clients) do
|
||||
table.insert(client_names, client.name)
|
||||
end
|
||||
return " " .. table.concat(client_names, ", ")
|
||||
end,
|
||||
color = { fg = colors.cyan },
|
||||
separator = { left = "" }
|
||||
},
|
||||
{
|
||||
"filesize",
|
||||
cond = function() return vim.fn.getfsize(vim.fn.expand('%:p')) > 0 end,
|
||||
separator = { left = "" }
|
||||
},
|
||||
{
|
||||
"encoding",
|
||||
cond = function() return vim.bo.fileencoding ~= 'utf-8' end,
|
||||
separator = { left = "" }
|
||||
},
|
||||
{
|
||||
"filetype",
|
||||
icons_enabled = true,
|
||||
separator = { left = "" }
|
||||
}
|
||||
},
|
||||
lualine_y = {
|
||||
{
|
||||
"progress",
|
||||
separator = { left = "" }
|
||||
}
|
||||
},
|
||||
lualine_z = {
|
||||
{
|
||||
"location",
|
||||
separator = { left = "" }
|
||||
}
|
||||
},
|
||||
},
|
||||
inactive_sections = {
|
||||
lualine_a = {},
|
||||
lualine_b = {},
|
||||
lualine_c = { { "filename", path = 1 } },
|
||||
lualine_x = { "location" },
|
||||
lualine_y = {},
|
||||
lualine_z = {},
|
||||
},
|
||||
tabline = {},
|
||||
winbar = {},
|
||||
inactive_winbar = {},
|
||||
extensions = {}
|
||||
}
|
||||
extensions = { "nvim-tree", "fzf", "lazy" },
|
||||
},
|
||||
}
|
||||
Reference in New Issue
Block a user