From ba4579bd66e7f901b61d6eaac4448c18afa38a4c Mon Sep 17 00:00:00 2001 From: Arsham Shirvani Date: Sat, 22 Oct 2022 11:50:28 +0100 Subject: [PATCH] ref(plugins): replace lua-dev with neodev --- README.md | 2 +- lua/plugins.lua | 11 ++++++++--- lua/settings/lsp/init.lua | 4 ++-- lua/settings/neodev-nvim.lua | 6 ++++++ 4 files changed, 17 insertions(+), 6 deletions(-) create mode 100644 lua/settings/neodev-nvim.lua diff --git a/README.md b/README.md index 70ca715..3141ef0 100644 --- a/README.md +++ b/README.md @@ -196,7 +196,7 @@ Some plugins are not listed here. You can find the complete list in the | Core | [tmux-plugins/vim-tmux](https://github.com/tmux-plugins/vim-tmux) | | | Core | [tpope/vim-git](https://github.com/tpope/vim-git) | | | Core | [andymass/vim-matchup](https://github.com/andymass/vim-matchup) | | -| Core | [folke/lua-dev.nvim](https://github.com/folke/lua-dev.nvim) | | +| Core | [folke/neodev.nvim](https://github.com/folke/neodev.nvim) | | | Core | [mattn/webapi-vim](https://github.com/mattn/webapi-vim) | | | Core | [milisims/nvim-luaref](https://github.com/milisims/nvim-luaref) | | | Core | [nvim-lua/plenary.nvim](https://github.com/nvim-lua/plenary.nvim) | | diff --git a/lua/plugins.lua b/lua/plugins.lua index 0452608..8d67964 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -478,9 +478,14 @@ packer.startup({ }) use({ - "folke/lua-dev.nvim", - ft = { "lua" }, - cond = { full_start, lsp_enabled }, + "folke/neodev.nvim", + config = function() + require("neodev").setup({}) + end, + wants = { "nvim-lspconfig" }, + after = { "nvim-lspconfig" }, + ft = { "lua" }, + cond = { full_start, lsp_enabled }, }) use({ diff --git a/lua/settings/lsp/init.lua b/lua/settings/lsp/init.lua index f73aefb..90ebb72 100644 --- a/lua/settings/lsp/init.lua +++ b/lua/settings/lsp/init.lua @@ -78,7 +78,7 @@ local servers = { sumneko_lua = { --{{{ opts = {}, update = function(on_attach, opts) - opts = require("lua-dev").setup({ + opts = { library = { plugins = { "arshlib.nvim", "plenary.nvim" }, }, @@ -113,7 +113,7 @@ local servers = { }, }, }, - }) + } opts.on_attach = function(client, bufnr) client.server_capabilities.documentFormattingProvider = false client.server_capabilities.documentRangeFormattingProvider = false diff --git a/lua/settings/neodev-nvim.lua b/lua/settings/neodev-nvim.lua new file mode 100644 index 0000000..6502018 --- /dev/null +++ b/lua/settings/neodev-nvim.lua @@ -0,0 +1,6 @@ +require("neodev").setup({ + library = { + plugins = { "arshlib.nvim", "plenary.nvim" }, + }, + runtime_path = true, +})