mirror of
https://github.com/tomru/nvim.git
synced 2026-03-03 06:27:14 +01:00
add bcr specific vtsls config
This commit is contained in:
@@ -201,6 +201,26 @@ return {
|
|||||||
-- ts_ls = {},
|
-- ts_ls = {},
|
||||||
--
|
--
|
||||||
|
|
||||||
|
vtsls = {
|
||||||
|
root_dir = function(bufnr, cb)
|
||||||
|
local fname = vim.api.nvim_buf_get_name(bufnr)
|
||||||
|
|
||||||
|
if fname:find 'frontend%-apps/bcr/core/public' then
|
||||||
|
-- yes, so use the core root
|
||||||
|
local root = vim.fs.root(fname, { 'apps/core/public/' })
|
||||||
|
cb(root)
|
||||||
|
elseif fname:find 'frontend%-apps/bcr' then
|
||||||
|
-- am I in core?
|
||||||
|
local root = vim.fs.root(fname, { 'apps/' })
|
||||||
|
cb(root)
|
||||||
|
else
|
||||||
|
local default_markers = { 'tsconfig.json', 'package.json', 'jsconfig.json', '.git' }
|
||||||
|
local root = vim.fs.root(fname, default_markers)
|
||||||
|
cb(root)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
|
||||||
lua_ls = {
|
lua_ls = {
|
||||||
-- cmd = { ... },
|
-- cmd = { ... },
|
||||||
-- filetypes = { ... },
|
-- filetypes = { ... },
|
||||||
|
|||||||
Reference in New Issue
Block a user