diff --git a/laptop/plugins.lua b/laptop/plugins.lua index 40d6149..f5a3592 100644 --- a/laptop/plugins.lua +++ b/laptop/plugins.lua @@ -28,12 +28,17 @@ require("lazy").setup({ -- LSP related plugins "neovim/nvim-lspconfig", "nvim-lua/plenary.nvim", - "hrsh7th/nvim-cmp", -- For LSP completion - "hrsh7th/cmp-nvim-lsp", - "hrsh7th/cmp-buffer", - "hrsh7th/cmp-omni", -- For LaTeX completion - "hrsh7th/cmp-path", - "hrsh7th/cmp-cmdline", + { + "hrsh7th/nvim-cmp", -- For LSP completion + event = "InsertEnter", + dependencies = { + "hrsh7th/cmp-nvim-lsp", + "hrsh7th/cmp-buffer", + "hrsh7th/cmp-omni", -- For LaTeX completion + "hrsh7th/cmp-path", + "hrsh7th/cmp-cmdline", + } + }, "SirVer/ultisnips", -- For snippets -- Support programming terms { "psliwka/vim-dirtytalk", build = ":DirtytalkUpdate" }, diff --git a/server/plugins.lua b/server/plugins.lua index 8ac36d3..ca0672e 100644 --- a/server/plugins.lua +++ b/server/plugins.lua @@ -25,11 +25,16 @@ require("lazy").setup({ "sitiom/nvim-numbertoggle", -- LSP related plugins "neovim/nvim-lspconfig", - "hrsh7th/nvim-cmp", -- For LSP completion - "hrsh7th/cmp-nvim-lsp", - "hrsh7th/cmp-cmdline", - "hrsh7th/cmp-buffer", - "hrsh7th/cmp-path", + { + "hrsh7th/nvim-cmp", -- For LSP completion + event = "InsertEnter", + dependencies = { + "hrsh7th/cmp-nvim-lsp", + "hrsh7th/cmp-cmdline", + "hrsh7th/cmp-buffer", + "hrsh7th/cmp-path", + } + }, -- Support programming terms { "psliwka/vim-dirtytalk", build = ":DirtytalkUpdate" }, -- vim-moonfly theme diff --git a/vps/plugins.lua b/vps/plugins.lua index 3ba8857..8229338 100644 --- a/vps/plugins.lua +++ b/vps/plugins.lua @@ -25,11 +25,16 @@ require("lazy").setup({ "sitiom/nvim-numbertoggle", -- LSP related plugins "neovim/nvim-lspconfig", - "hrsh7th/nvim-cmp", -- For LSP completion - "hrsh7th/cmp-nvim-lsp", - "hrsh7th/cmp-buffer", - "hrsh7th/cmp-path", - "hrsh7th/cmp-cmdline", + { + "hrsh7th/nvim-cmp", -- For LSP completion + event = "InsertLeave", + dependencies = { + "hrsh7th/cmp-nvim-lsp", + "hrsh7th/cmp-buffer", + "hrsh7th/cmp-path", + "hrsh7th/cmp-cmdline", + } + }, -- Support programming terms { "psliwka/vim-dirtytalk", build = ":DirtytalkUpdate" }, -- vim-moonfly theme