From 3a2f4e3e700384859f0a5026a59460a670e9108c Mon Sep 17 00:00:00 2001 From: rootiest Date: Wed, 2 Apr 2025 16:16:27 -0400 Subject: [PATCH] revert(statuscolumn): remove statuscolumn diagnostic colors This code was not functioning properly so in the interest of performance, it is to be removed until it can be fixed --- lua/config/statuscolumn.lua | 46 +++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 22 deletions(-) diff --git a/lua/config/statuscolumn.lua b/lua/config/statuscolumn.lua index 7567efc..c8b97c9 100644 --- a/lua/config/statuscolumn.lua +++ b/lua/config/statuscolumn.lua @@ -93,28 +93,30 @@ _G.CustomStatusColumn = function() -- Use the plugin's original status column local original_statuscolumn = require('snacks.statuscolumn').get() - -- Check for diagnostics on the current line - local diagnostics = vim.diagnostic.get(0, { lnum = lnum - 1 }) -- Get diagnostics for the current line (subtract 1 for 0-based index) - local highlight_group = nil - - -- Loop through diagnostics to determine highlight group based on severity - for _, diagnostic in ipairs(diagnostics) do - if diagnostic.severity == vim.diagnostic.severity.ERROR then - highlight_group = 'DiagnosticSignError' - break - elseif diagnostic.severity == vim.diagnostic.severity.WARN then - highlight_group = 'DiagnosticSignWarn' - elseif diagnostic.severity == vim.diagnostic.severity.INFO then - highlight_group = 'DiagnosticSignInfo' - elseif diagnostic.severity == vim.diagnostic.severity.HINT then - highlight_group = 'DiagnosticSignHint' - end - end - - -- Highlight for lines with diagnostics - if highlight_group then - return '%#' .. highlight_group .. '#' .. original_statuscolumn .. '%*' -- Use the corresponding highlight for this line - end + --FIXME: Diagnistics indications currently non-functional + -- + -- -- Check for diagnostics on the current line + -- local diagnostics = vim.diagnostic.get(0, { lnum = lnum - 1 }) -- Get diagnostics for the current line (subtract 1 for 0-based index) + -- local highlight_group = nil + -- + -- -- Loop through diagnostics to determine highlight group based on severity + -- for _, diagnostic in ipairs(diagnostics) do + -- if diagnostic.severity == vim.diagnostic.severity.ERROR then + -- highlight_group = 'DiagnosticSignError' + -- break + -- elseif diagnostic.severity == vim.diagnostic.severity.WARN then + -- highlight_group = 'DiagnosticSignWarn' + -- elseif diagnostic.severity == vim.diagnostic.severity.INFO then + -- highlight_group = 'DiagnosticSignInfo' + -- elseif diagnostic.severity == vim.diagnostic.severity.HINT then + -- highlight_group = 'DiagnosticSignHint' + -- end + -- end + -- + -- -- Highlight for lines with diagnostics + -- if highlight_group then + -- return '%#' .. highlight_group .. '#' .. original_statuscolumn .. '%*' -- Use the corresponding highlight for this line + -- end -- Highlight for the current line if lnum == cursor_lnum then