diff --git a/neovim/.config/nvim/after/plugin/lsp.lua b/neovim/.config/nvim/after/plugin/lsp.lua index 9f9946c..fa705e1 100644 --- a/neovim/.config/nvim/after/plugin/lsp.lua +++ b/neovim/.config/nvim/after/plugin/lsp.lua @@ -87,16 +87,13 @@ for _, server in ipairs(servers) do local opts = { capabilities = capabilities, on_attach = on_attach, + root_dir = util.root_pattern(".git"), } if server.name == "emmet_ls" then opts.filetypes = { "html", "css", "scss", "javascripreact", "typescriptreact" } end - if server.name == "tailwindcss" then - opts.root_dir = util.root_pattern("tailwind.config.js", "tailwind.config.cjs", "tailwind.config.mjs") - end - if server.name == "sumneko_lua" then local luadev = require("lua-dev").setup({ lspconfig = { @@ -144,7 +141,6 @@ for _, server in ipairs(servers) do end if server.name == "tsserver" then - opts.root_dir = util.root_pattern(".git", "package.json", "tsconfig.json") opts.settings = { tsserver = { experimental = { @@ -164,10 +160,6 @@ for _, server in ipairs(servers) do } end - if server.name == "eslint" then - opts.root_dir = util.root_pattern(".eslintrc", ".eslintrc.json") - end - if server.name == "denols" then opts.root_dir = util.root_pattern("deno.json", "deps.ts") end