From db29bb10515e7f87c2bd94170859b9a967a16756 Mon Sep 17 00:00:00 2001 From: ray-x Date: Wed, 19 Oct 2022 20:00:28 +1100 Subject: [PATCH] update deprecated messages --- README.md | 7 ++++--- lua/navigator/lspclient/clients.lua | 20 +++----------------- 2 files changed, 7 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 7753911..385bff4 100644 --- a/README.md +++ b/README.md @@ -699,15 +699,16 @@ Here is an example [init_lsp_installer.lua](https://github.com/ray-x/navigator.l There are lots of plugins provides lsp support * go.nvim allow you either hook gopls from go.nvim or from navigator and it can export the lsp setup from go.nvim. * rust-tools and clangd allow you to setup on_attach from config server -* [neodev](https://github.com/folke/neodev.nvim) Dev setup for init.lua and plugin development. Navigator can -extend lua setup with neodev. +* [neodev](https://github.com/folke/neodev.nvim) Dev setup for lua development. Navigator help you setup neodev + Here is an example to setup rust with rust-tools ```lua require'navigator'.setup({ lsp = { disable_lsp = { "rust_analyzer", "clangd" }, -- will not run rust_analyzer setup from navigator - ['neodev'] = { runtime_path=true } -- any non default neodev setups + ['neodev'] = { runtime_path=true } -- any non default neodev setups, if not empty, navigator will call neodev.setup + -- with those configures }, }) diff --git a/lua/navigator/lspclient/clients.lua b/lua/navigator/lspclient/clients.lua index 4640b3b..4259ccd 100644 --- a/lua/navigator/lspclient/clients.lua +++ b/lua/navigator/lspclient/clients.lua @@ -50,25 +50,11 @@ local on_attach = require('navigator.lspclient.attach').on_attach -- gopls["ui.completion.usePlaceholders"] = true -- lua setup -local library = {} - -local luadevcfg = { - library = { - vimruntime = true, -- runtime path - types = true, -- full signature, docs and completion of vim.api, vim.treesitter, vim.lsp and others - plugins = { 'nvim-treesitter', 'plenary.nvim' }, - }, - lspconfig = { - -- cmd = {sumneko_binary}, - on_attach = on_attach, - }, -} -local luadev = {} -local user_luadev = _NgConfigValues.lsp['neodev'] -if next(user_luadev) then - luadev = vim.tbl_deep_extend('force', luadev, user_luadev) +if _NgConfigValues.lsp['lua-dev'] ~= nil then + vim.notify('lua-dev is deprecated, please use neodev instead', vim.lsp.log_levels.WARN) end + require('navigator.lazyloader').load('neodev.nvim', 'folke/neodev.nvim') if _NgConfigValues.mason then