diff --git a/lua/lazyvim/util/plugin.lua b/lua/lazyvim/util/plugin.lua index 75d49899..f23bec3b 100644 --- a/lua/lazyvim/util/plugin.lua +++ b/lua/lazyvim/util/plugin.lua @@ -14,6 +14,12 @@ M.deprecated_extras = { ["lazyvim.plugins.extras.ui.dashboard"] = "`dashboard.nvim` is now the default **LazyVim** starter.", } +M.deprecated_modules = { + ["null-ls"] = "lsp.none-ls", + ["nvim-navic.lib"] = "editor.navic", + ["nvim-navic"] = "editor.navic", +} + ---@type table M.renames = { ["windwp/nvim-spectre"] = "nvim-pack/nvim-spectre", @@ -26,6 +32,18 @@ function M.setup() M.fix_imports() M.fix_renames() M.lazy_file() + table.insert(package.loaders, function(module) + if M.deprecated_modules[module] then + Util.warn( + ("`%s` is no longer included by default in **LazyVim**.\nPlease install the `%s` extra if you still want to use it."):format( + module, + M.deprecated_modules[module] + ), + { title = "LazyVim" } + ) + return function() end + end + end) end function M.extra_idx(name)