summaryrefslogtreecommitdiff
path: root/script/config/template.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-06-08 19:49:15 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-06-08 19:49:15 +0800
commita452b6196ecad1d5812558a53a7808104ec40e9d (patch)
treeb91791226f036f6914609a0aa6d8d4287a6aba0d /script/config/template.lua
parentc6e028f7eba7933bf1b6146284446dd9619da00f (diff)
downloadlua-language-server-a452b6196ecad1d5812558a53a7808104ec40e9d.zip
update config
Diffstat (limited to 'script/config/template.lua')
-rw-r--r--script/config/template.lua20
1 files changed, 16 insertions, 4 deletions
diff --git a/script/config/template.lua b/script/config/template.lua
index bea1dfa1..3e5b11a6 100644
--- a/script/config/template.lua
+++ b/script/config/template.lua
@@ -217,16 +217,28 @@ local template = {
'enable',
'disable',
}
- ),
+ )
+ >> util.deepCopy(define.BuiltIn),
['Lua.diagnostics.enable'] = Type.Boolean >> true,
['Lua.diagnostics.globals'] = Type.Array(Type.String),
['Lua.diagnostics.disable'] = Type.Array(Type.String),
- ['Lua.diagnostics.severity'] = Type.Hash(Type.String, Type.String)
+ ['Lua.diagnostics.severity'] = Type.Hash(
+ Type.String << util.getTableKeys(define.DiagnosticDefaultNeededFileStatus, true),
+ Type.String << {
+ 'Error',
+ 'Warning',
+ 'Information',
+ 'Hint',
+ }
+ )
>> util.deepCopy(define.DiagnosticDefaultSeverity),
- ['Lua.diagnostics.neededFileStatus'] = Type.Hash(Type.String, Type.String)
+ ['Lua.diagnostics.neededFileStatus'] = Type.Hash(
+ Type.String << util.getTableKeys(define.DiagnosticDefaultNeededFileStatus, true),
+ Type.String << { 'Any', 'Opened', 'None' }
+ )
>> util.deepCopy(define.DiagnosticDefaultNeededFileStatus),
['Lua.diagnostics.disableScheme'] = Type.Array(Type.String) >> { 'git' },
- ['Lua.diagnostics.workspaceDelay'] = Type.Integer >> 5,
+ ['Lua.diagnostics.workspaceDelay'] = Type.Integer >> 3000,
['Lua.diagnostics.workspaceRate'] = Type.Integer >> 100,
['Lua.diagnostics.libraryFiles'] = Type.String >> 'Opened' << {
'Enable',