fix(nvim): fixes eslint commant for EFM LS and start it for typescript

and glimmer files
This commit is contained in:
Bruno Carlin 2025-02-11 15:23:05 +01:00
parent 714007013b
commit f4ee62d918

View file

@ -1,7 +1,8 @@
local eslint = { local eslint = {
lintCommand = 'eslint -f visualstudio --stdin --stdin-filename ${INPUT}', lintCommand = 'npx eslint -f visualstudio --cache --stdin --stdin-filename ${INPUT}',
lintIgnoreExitCode = true, lintIgnoreExitCode = true,
lintStdin = true, lintStdin = true,
rootMarkers = { "package.json" },
lintFormats = { lintFormats = {
"%f(%l,%c): %tarning %m", "%f(%l,%c): %tarning %m",
"%f(%l,%c): %trror %m", "%f(%l,%c): %trror %m",
@ -54,12 +55,16 @@ local hadolint = {
require('lspconfig').efm.setup { require('lspconfig').efm.setup {
cmd = {'efm-langserver'},
filetypes = { filetypes = {
"bash", "bash",
"css", "css",
"dockerfile", "dockerfile",
"fish", "fish",
"javascript", "javascript",
"typescript",
"javascript.glimmer",
"typescript.glimmer",
"markdown", "markdown",
"scss", "scss",
"sh", "sh",
@ -73,6 +78,9 @@ require('lspconfig').efm.setup {
dockerfile = { hadolint }, dockerfile = { hadolint },
fish = { fish }, fish = { fish },
javascript = { eslint }, javascript = { eslint },
typescript = { eslint },
["javascript.glimmer"] = { eslint },
["typescript.glimmer"] = { eslint },
markdown = { mdlint }, markdown = { mdlint },
scss = { stylelint }, scss = { stylelint },
sh = { shellcheck }, sh = { shellcheck },