aboutsummaryrefslogtreecommitdiffstats
path: root/lua/nvim-lsp-installer/servers/angularls
diff options
context:
space:
mode:
authorkylo252 <59826753+kylo252@users.noreply.github.com>2021-10-18 14:04:54 +0200
committerGitHub <noreply@github.com>2021-10-18 14:04:54 +0200
commitc87e2fec9f54a438ddfd50642426a2dd628de180 (patch)
tree3970936cb1227ccfde5a809f3e6fdb30d5a1aa3e /lua/nvim-lsp-installer/servers/angularls
parentsort :LspInstall, :LspUninstall completion items (diff)
downloadmason-c87e2fec9f54a438ddfd50642426a2dd628de180.tar
mason-c87e2fec9f54a438ddfd50642426a2dd628de180.tar.gz
mason-c87e2fec9f54a438ddfd50642426a2dd628de180.tar.bz2
mason-c87e2fec9f54a438ddfd50642426a2dd628de180.tar.lz
mason-c87e2fec9f54a438ddfd50642426a2dd628de180.tar.xz
mason-c87e2fec9f54a438ddfd50642426a2dd628de180.tar.zst
mason-c87e2fec9f54a438ddfd50642426a2dd628de180.zip
feat: autogen metadata table(s) (#159)
Co-authored-by: William Boman <william@redwill.se>
Diffstat (limited to 'lua/nvim-lsp-installer/servers/angularls')
-rw-r--r--lua/nvim-lsp-installer/servers/angularls/init.lua19
1 files changed, 10 insertions, 9 deletions
diff --git a/lua/nvim-lsp-installer/servers/angularls/init.lua b/lua/nvim-lsp-installer/servers/angularls/init.lua
index 5a545cd2..102ad32f 100644
--- a/lua/nvim-lsp-installer/servers/angularls/init.lua
+++ b/lua/nvim-lsp-installer/servers/angularls/init.lua
@@ -1,17 +1,18 @@
-local util = require "lspconfig/util"
local server = require "nvim-lsp-installer.server"
local npm = require "nvim-lsp-installer.installers.npm"
--- Angular requires a node_modules directory to probe for @angular/language-service and typescript
--- in order to use your projects configured versions.
--- This defaults to the vim cwd, but will get overwritten by the resolved root of the file.
-local function get_probe_dir(root_dir)
- local project_root = util.find_node_modules_ancestor(root_dir)
+return function(name, root_dir)
+ local util = require "lspconfig/util"
+ --
+ -- Angular requires a node_modules directory to probe for @angular/language-service and typescript
+ -- in order to use your projects configured versions.
+ -- This defaults to the vim cwd, but will get overwritten by the resolved root of the file.
+ local function get_probe_dir(root_dir)
+ local project_root = util.find_node_modules_ancestor(root_dir)
- return project_root and (project_root .. "/node_modules") or ""
-end
+ return project_root and (project_root .. "/node_modules") or ""
+ end
-return function(name, root_dir)
local default_probe_dir = get_probe_dir(vim.fn.getcwd())
local executable_path = npm.executable(root_dir, "ngserver")