Split LSP package definitions to avoid monolithic dependencies list, and add more flexibility

This commit is contained in:
Evie Litherland-Smith 2023-02-21 07:07:42 +00:00
parent 396e683145
commit 7999de3fca

View file

@ -1,22 +1,11 @@
return { return {
{
"neovim/nvim-lspconfig", "neovim/nvim-lspconfig",
event = { "BufReadPre", "BufNewFile" }, event = { "BufReadPre", "BufNewFile" },
dependencies = { dependencies = {
{ "hrsh7th/nvim-cmp" }, { "hrsh7th/nvim-cmp" },
{ "hrsh7th/cmp-nvim-lsp" },
{ "hrsh7th/cmp-buffer" },
{ "hrsh7th/cmp-path" },
{ "hrsh7th/cmp-cmdline" },
{ "f3fora/cmp-spell" },
{ "petertriho/cmp-git" },
{ "Dosx001/cmp-commit" },
{ "kdheepak/cmp-latex-symbols" },
{ "L3MON4D3/LuaSnip" },
{ "saadparwaiz1/cmp_luasnip" },
{ "rafamadriz/friendly-snippets" }, { "rafamadriz/friendly-snippets" },
{ "windwp/nvim-autopairs" }, { "windwp/nvim-autopairs" },
{ "jose-elias-alvarez/null-ls.nvim" },
{ "folke/neodev.nvim" },
}, },
config = function() config = function()
local config = require "lsp.config" local config = require "lsp.config"
@ -28,4 +17,23 @@ return {
} }
require "lsp.cmp" require "lsp.cmp"
end, end,
},
{
"hrsh7th/nvim-cmp",
dependencies = {
{ "hrsh7th/cmp-nvim-lsp" },
{ "hrsh7th/cmp-buffer" },
{ "hrsh7th/cmp-path" },
{ "hrsh7th/cmp-cmdline" },
{ "f3fora/cmp-spell" },
{ "petertriho/cmp-git" },
{ "Dosx001/cmp-commit" },
{ "kdheepak/cmp-latex-symbols" },
{ "L3MON4D3/LuaSnip" },
{ "saadparwaiz1/cmp_luasnip" },
},
cmd = "CmpStatus",
},
{ "jose-elias-alvarez/null-ls.nvim", dependencies = { "neovim/nvim-lspconfig" }, lazy = true },
{ "folke/neodev.nvim", dependencies = { "neovim/nvim-lspconfig", "hrsh7th/nvim-cmp" }, lazy = true },
} }