style: apply formatting

This commit is contained in:
2026-04-13 23:24:31 +02:00
parent 959cec7051
commit 5468a5a628
17 changed files with 115 additions and 107 deletions
+18 -6
View File
@@ -246,10 +246,17 @@ function Linter.validate(config)
vim.validate("config", config, "table")
vim.validate("cmd", config.cmd, list_of("string"), "list of strings")
vim.validate(
"events", config.events, list_of("string"), true, "list of strings"
"events",
config.events,
list_of("string"),
true,
"list of strings"
)
vim.validate(
"clear_events", config.clear_events, list_of("string"), true,
"clear_events",
config.clear_events,
list_of("string"),
true,
"list of strings"
)
vim.validate("stdin", config.stdin, "boolean", true)
@@ -257,12 +264,15 @@ function Linter.validate(config)
vim.validate("stderr", config.stderr, "boolean", true)
vim.validate("pattern", config.pattern, "string", true)
vim.validate(
"groups", config.groups, list_of("string"), true, "list of strings"
"groups",
config.groups,
list_of("string"),
true,
"list of strings"
)
vim.validate("severity_map", config.severity_map, function(t)
return util.is_map(t, "string", "number")
end, true, "map of string to number"
)
end, true, "map of string to number")
vim.validate("debounce", config.debounce, "number", true)
vim.validate("source", config.source, "string", true)
vim.validate("json", config.json, "table", true)
@@ -430,7 +440,9 @@ function Linter.add(bufnr, config)
end, config.debounce)
vim.api.nvim_create_autocmd(config.events, {
buffer = linter.bufnr,
callback = function() debouncer:call() end,
callback = function()
debouncer:call()
end,
group = linter.augroup,
})