From fde77fd7bb62d5766cf0e1663eb85a5b220c192c Mon Sep 17 00:00:00 2001 From: Dane Sabo Date: Wed, 19 Feb 2025 20:40:28 -0500 Subject: [PATCH] added md to ts --- lua/custom/chadrc.lua | 2 +- lua/custom/configs/lspconfig.lua | 21 --------------------- lua/custom/mappings.lua | 18 ++++++++++++++++++ lua/plugins/configs/treesitter.lua | 2 +- 4 files changed, 20 insertions(+), 23 deletions(-) diff --git a/lua/custom/chadrc.lua b/lua/custom/chadrc.lua index 8903a5f..b9922f5 100644 --- a/lua/custom/chadrc.lua +++ b/lua/custom/chadrc.lua @@ -1,7 +1,7 @@ ---@type ChadrcConfig local M = {} -M.ui = { theme = 'oceanic-light' } +M.ui = { theme = 'one_light' } M.plugins = 'custom.plugins' M.mappings = require "custom.mappings" return M diff --git a/lua/custom/configs/lspconfig.lua b/lua/custom/configs/lspconfig.lua index f025bb3..fd641a9 100644 --- a/lua/custom/configs/lspconfig.lua +++ b/lua/custom/configs/lspconfig.lua @@ -19,7 +19,6 @@ local lspconfig = require("lspconfig") local servers = { "pyright", - "ruff_lsp" } for _, lsp in ipairs(servers) do @@ -44,28 +43,8 @@ lspconfig.hls.setup{ filetypes = {'haskell', 'lhaskell', 'cabal'} } - - lspconfig.matlab_ls.setup{ on_attach = on_attach, capabilities = capabilities, filetypes = {'matlab'} } - --- Function to show diagnostics on hover -vim.api.nvim_create_autocmd("CursorHold", { - callback = function() - local opts = { - focusable = false, - close_events = { "BufLeave", "CursorMoved", "InsertEnter", "FocusLost" }, - border = 'rounded', - source = 'always', -- show source in diagnostics popup window - prefix = ' ', - scope = 'cursor', - } - vim.diagnostic.open_float(nil, opts) - end -}) - --- Optional: keybinding to manually show diagnostics on hover -vim.api.nvim_set_keymap('n', 'e', 'lua vim.diagnostic.open_float()', { noremap = true, silent = true }) diff --git a/lua/custom/mappings.lua b/lua/custom/mappings.lua index b4876cd..ff10328 100644 --- a/lua/custom/mappings.lua +++ b/lua/custom/mappings.lua @@ -27,6 +27,24 @@ M.crates = { } } +-- Function to show diagnostics on hover +vim.api.nvim_create_autocmd("CursorHold", { + callback = function() + local opts = { + focusable = false, + close_events = { "BufLeave", "CursorMoved", "InsertEnter", "FocusLost" }, + border = 'rounded', + source = 'always', -- show source in diagnostics popup window + prefix = ' ', + scope = 'cursor', + } + vim.diagnostic.open_float(nil, opts) + end +}) + +-- Optional: keybinding to manually show diagnostics on hover +vim.api.nvim_set_keymap('n', 'e', 'lua vim.diagnostic.open_float()', { noremap = true, silent = true }) + require("custom.language_specific_commands.matlab") return M diff --git a/lua/plugins/configs/treesitter.lua b/lua/plugins/configs/treesitter.lua index 1514f7c..e146848 100644 --- a/lua/plugins/configs/treesitter.lua +++ b/lua/plugins/configs/treesitter.lua @@ -1,5 +1,5 @@ local options = { - ensure_installed = { "lua", "vim", "vimdoc","c","rust","haskell", "matlab", "tlaplus"}, + ensure_installed = { "lua", "vim", "vimdoc","c","rust","haskell", "matlab", "tlaplus", "markdown"}, highlight = { enable = true,