add 'full' for line_width in diagnostics options (#2452)

* add 'full' for line_width in diagnostics options

* lowercase documentation entry and change error notify method

* moved line_width options checking
This commit is contained in:
blue pitaya
2023-09-03 21:15:21 +02:00
committed by GitHub
parent 3fae9c1e14
commit dc7f25c810
3 changed files with 14 additions and 2 deletions

View File

@@ -146,6 +146,14 @@ diagnostics.get = function(opts)
return
end
if type(opts.line_width) == "string" and opts.line_width ~= "full" then
utils.notify("builtin.diagnostics", {
msg = string.format("'%s' is not a valid value for line_width", opts.line_width),
level = "ERROR",
})
return
end
opts.path_display = vim.F.if_nil(opts.path_display, "hidden")
pickers
.new(opts, {