GB7A3DGSETM45PMUFQZSAMMSVLTX2HJZTXBD4WLS7T4KFS37HCOQC YQNIE7T4PTQR7TYPXJUM577AXIHT5ZHE5UKUOKQHKYGINQCSM7VQC YBCUW6H3YJDQPUBHYL5BFLTRATYK7SYSCZNMIV3KKMMXD2W6XAQQC QLSJECGDTJIUHR5P7G4V4TLGQICL67R72RLXY7ON6P2BHMOTRFVQC GT35NGAHIVA7RXCZRK6OPFIC6KRVJ7SNI2AKVYLZLMVSBIKLOIEQC YQTJKSDUZ6Y6LSJGOKBYQOPG3IG5RFMRKO2JGVUN5Q7AHPGOWFTAC 526CRD2QD6NF6N6PQUNWZT6UUGNLMC25UYNIO7ZFUCPQCUALYN4QC KXYLAJ5WZIXV5FQ4TU3IPHCO2YRKQBAZBW27LOA5EVWI2OLVPIIAC RXJH46XLP6AFSIZZD4WEQA5A5YZLKHZ54ZUGCRH7TRAOH2Z4Q2VQC AH6HSGEDTDCT77KUZXFSBB3U22PORVZ2RFGEN2DHYJNUHG6UWDPAC local lsp = vim.lsplsp.set_log_level("off")local orig_util_open_floating_preview = lsp.util.open_floating_previewfunction lsp.util.open_floating_preview(contents, syntax, opts, ...)opts = opts or {}opts.max_width = opts.max_width or 60opts.focusable = opts.focusable or falsereturn orig_util_open_floating_preview(contents, syntax, opts, ...)end-- trying tiny-inline-diagnostic.nvim for a while-- callback = function()-- vim.diagnostic.open_float()-- end,-- })local function reload_lsp()local function check_and_reload()if not lsp.buf_is_attached(0) thenelsevim.defer_fn(check_and_reload, 50)endendvim.defer_fn(check_and_reload, 50)endreturn {}vim.api.nvim_create_user_command("LspReload", reload_lsp, { desc = "Reload attached LSP" })vim.cmd.edit()vim.cmd("lua vim.lsp.stop_client(vim.lsp.get_clients())")-- vim.api.nvim_create_autocmd("CursorHold", {
-- Global variablesCMD = vim.cmdAUTOCMD = vim.api.nvim_create_autocmdAUGROUP = vim.api.nvim_create_augroupCREATE_CMD = vim.api.nvim_create_user_commandMAP = vim.keymap.setSET_HL = vim.api.nvim_set_hl
{programs.nvf.settings.vim.luaConfigRC.globals = ''-- Global variablesCMD = vim.cmdAUTOCMD = vim.api.nvim_create_autocmdAUGROUP = vim.api.nvim_create_augroupCREATE_CMD = vim.api.nvim_create_user_commandMAP = vim.keymap.setSET_HL = vim.api.nvim_set_hl
-- Global functionsfunction ColorMyPencils(color, theme, transparent)vim.o.background = theme or "light"vim.cmd.colorscheme(color or "default")require("fidget").notify("background: " .. vim.o.background .. "\n theme: " .. theme .. "\n colorscheme: " .. color)
-- Global functionsfunction ColorMyPencils(color, theme, transparent)vim.o.background = theme or "light"vim.cmd.colorscheme(color or "default")require("fidget").notify("background: " .. vim.o.background .. "\n theme: " .. theme .. "\n colorscheme: " .. color)
-- general tweaksif transparent thenvim.api.nvim_set_hl(0, "Normal", { bg = "none" })vim.api.nvim_set_hl(0, "NormalFloat", { bg = "none" })vim.api.nvim_set_hl(0, "NormalNC", { bg = "none" })end
-- general tweaksif transparent thenvim.api.nvim_set_hl(0, "Normal", { bg = "none" })vim.api.nvim_set_hl(0, "NormalFloat", { bg = "none" })vim.api.nvim_set_hl(0, "NormalNC", { bg = "none" })end
if theme == "dark" thenvim.api.nvim_set_hl(0, "LineNrAbove", { fg = "#BFBFBF", bold = false })vim.api.nvim_set_hl(0, "LineNr", { fg = "white", bold = true })vim.api.nvim_set_hl(0, "LineNrBelow", { fg = "#BFBFBF", bold = false })end
if theme == "dark" thenvim.api.nvim_set_hl(0, "LineNrAbove", { fg = "#BFBFBF", bold = false })vim.api.nvim_set_hl(0, "LineNr", { fg = "white", bold = true })vim.api.nvim_set_hl(0, "LineNrBelow", { fg = "#BFBFBF", bold = false })end
-- fixes for colorschemesif color == "rusticated" thenFixRusticated()endif color == "rasmus" thenFixRasmus()endif color == "gruvbox-material" and theme == "light" thenvim.api.nvim_set_hl(0, "LineNrAbove", { fg = "#7C6F64", bold = true })vim.api.nvim_set_hl(0, "LineNrBelow", { fg = "#7C6F64", bold = true })vim.api.nvim_set_hl(0, "LineNr", { fg = "#4f3829", bold = true })endend
-- fixes for colorschemesif color == "rusticated" thenFixRusticated()endif color == "rasmus" thenFixRasmus()endif color == "gruvbox-material" and theme == "light" thenvim.api.nvim_set_hl(0, "LineNrAbove", { fg = "#7C6F64", bold = true })vim.api.nvim_set_hl(0, "LineNrBelow", { fg = "#7C6F64", bold = true })vim.api.nvim_set_hl(0, "LineNr", { fg = "#4f3829", bold = true })endend
for key, hl_group in pairs(hl_groups) doif hl_group.italic thenvim.api.nvim_set_hl(0, key, vim.tbl_extend("force", hl_group, { italic = false }))
for key, hl_group in pairs(hl_groups) doif hl_group.italic thenvim.api.nvim_set_hl(0, key, vim.tbl_extend("force", hl_group, { italic = false }))endend
for key, hl_group in pairs(hl_groups) doif hl_group.bold thenvim.api.nvim_set_hl(0, key, vim.tbl_extend("force", hl_group, { bold = false }))
for key, hl_group in pairs(hl_groups) doif hl_group.bold thenvim.api.nvim_set_hl(0, key, vim.tbl_extend("force", hl_group, { bold = false }))endend
endendfunction DisableUndercurl()local highlights = {DiagnosticUnderlineError = { undercurl = false, underline = true },DiagnosticUnderlineWarn = { undercurl = false, underline = true },DiagnosticUnderlineInfo = { undercurl = false, underline = true },DiagnosticUnderlineHint = { undercurl = false, underline = true },}
for group, opts in pairs(highlights) dovim.api.nvim_set_hl(0, group, opts)endend
function DisableUndercurl()local highlights = {DiagnosticUnderlineError = { undercurl = false, underline = true },DiagnosticUnderlineWarn = { undercurl = false, underline = true },DiagnosticUnderlineInfo = { undercurl = false, underline = true },DiagnosticUnderlineHint = { undercurl = false, underline = true },}
function FixRasmus()local highlights = {SpellBad = { undercurl = false, underline = true },SpellCap = { undercurl = false, underline = true },SpellLocal = { undercurl = false, underline = true },SpellRare = { undercurl = false, underline = true },DiffAdd = { reverse = false },DiffChange = { reverse = false },DiffDelete = { reverse = false },}
for group, opts in pairs(highlights) dovim.api.nvim_set_hl(0, group, opts)endend
for group, opts in pairs(highlights) dovim.api.nvim_set_hl(0, group, opts)endend
function FixRasmus()local highlights = {SpellBad = { undercurl = false, underline = true },SpellCap = { undercurl = false, underline = true },SpellLocal = { undercurl = false, underline = true },SpellRare = { undercurl = false, underline = true },DiffAdd = { reverse = false },DiffChange = { reverse = false },DiffDelete = { reverse = false },}
function FixRusticated()vim.api.nvim_set_hl(0, "DiffAdd", {fg = "#1e1e1e",bg = "#98c379",})
for group, opts in pairs(highlights) dovim.api.nvim_set_hl(0, group, opts)endend
if fe == "" or ff == "" thenreturn ""elseif fe ~= "utf-8" and ff ~= "unix" thenreturn fe .. " :: " .. ff .. " :: "elseif fe ~= "utf-8" and ff == "unix" thenreturn fe .. " :: "elseif fe == "utf-8" and ff ~= "unix" thenreturn ff .. " :: "elsereturn ""endend
function LualineFileInfo()local fe = vim.o.fileencodinglocal ff = vim.o.fileformat
function LualinePomoTimer()local ok, pomo = pcall(require, "pomo")if not ok thenreturn ""end
if fe == "" or ff == "" thenreturn ""elseif fe ~= "utf-8" and ff ~= "unix" thenreturn fe .. " :: " .. ff .. " :: "elseif fe ~= "utf-8" and ff == "unix" thenreturn fe .. " :: "elseif fe == "utf-8" and ff ~= "unix" thenreturn ff .. " :: "elsereturn ""endend