diff --git a/lua/lspconfiguration.lua b/lua/lspconfiguration.lua index a893edc..eaee051 100644 --- a/lua/lspconfiguration.lua +++ b/lua/lspconfiguration.lua @@ -64,3 +64,21 @@ vim.lsp.config("vhdl_ls", { root_markers = { "vhdl_ls.toml", ".git" }, settings = {}, }) + +local registry = require("mason-registry") + +registry:on("package:install:success", function(pkg) + vim.schedule(function() + vim.notify("Installed " .. pkg.name) + + -- Formatter neu laden + package.loaded["formatter"] = nil + require("formatter") + + -- ALE reset + vim.cmd("ALEFixSuggest") -- oder ALELint + + -- LSP neu attachen + vim.cmd("LspRestart") + end) +end)