149 lines
6.3 KiB
JSON
149 lines
6.3 KiB
JSON
{
|
|
"$schema": "http://json-schema.org/schema",
|
|
"title": "ZLS Config",
|
|
"description": "Configuration file for the zig language server (ZLS)",
|
|
"type": "object",
|
|
"properties": {
|
|
"enable_snippets": {
|
|
"description": "Enables snippet completions when the client also supports them",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"enable_ast_check_diagnostics": {
|
|
"description": "Whether to enable ast-check diagnostics",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"enable_autofix": {
|
|
"description": "Whether to automatically fix errors on save. Currently supports adding and removing discards.",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"enable_import_embedfile_argument_completions": {
|
|
"description": "Whether to enable import/embedFile argument completions",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"semantic_tokens": {
|
|
"description": "Set level of semantic tokens. Partial only includes information that requires semantic analysis.",
|
|
"type": "string",
|
|
"enum": [
|
|
"none",
|
|
"partial",
|
|
"full"
|
|
],
|
|
"default": "full"
|
|
},
|
|
"enable_inlay_hints": {
|
|
"description": "Enables inlay hint support when the client also supports it",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"inlay_hints_show_builtin": {
|
|
"description": "Enable inlay hints for builtin functions",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"inlay_hints_exclude_single_argument": {
|
|
"description": "Don't show inlay hints for single argument calls",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"inlay_hints_hide_redundant_param_names": {
|
|
"description": "Hides inlay hints when parameter name matches the identifier (e.g. foo: foo)",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"inlay_hints_hide_redundant_param_names_last_token": {
|
|
"description": "Hides inlay hints when parameter name matches the last token of a parameter node (e.g. foo: bar.foo, foo: &foo)",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"operator_completions": {
|
|
"description": "Enables `*` and `?` operators in completion lists",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"warn_style": {
|
|
"description": "Enables warnings for style guideline mismatches",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"highlight_global_var_declarations": {
|
|
"description": "Whether to highlight global var declarations",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"dangerous_comptime_experiments_do_not_enable": {
|
|
"description": "Whether to use the comptime interpreter",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"include_at_in_builtins": {
|
|
"description": "Whether the @ sign should be part of the completion of builtins",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"skip_std_references": {
|
|
"description": "When true, skips searching for references in std. Improves lookup speed for functions in user's code. Renaming and go-to-definition will continue to work as is",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"max_detail_length": {
|
|
"description": "The detail field of completions is truncated to be no longer than this (in bytes)",
|
|
"type": "integer",
|
|
"default": "1048576"
|
|
},
|
|
"prefer_ast_check_as_child_process": {
|
|
"description": "Can be used in conjuction with `enable_ast_check_diagnostics` to favor using `zig ast-check` instead of ZLS's fork",
|
|
"type": "boolean",
|
|
"default": "true"
|
|
},
|
|
"record_session": {
|
|
"description": "When true, zls will record all request is receives and write in into `record_session_path`, so that they can replayed with `zls replay`",
|
|
"type": "boolean",
|
|
"default": "false"
|
|
},
|
|
"record_session_path": {
|
|
"description": "Output file path when `record_session` is set. The recommended file extension *.zlsreplay",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"replay_session_path": {
|
|
"description": "Used when calling `zls replay` for specifying the replay file. If no extra argument is given `record_session_path` is used as the default path.",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"builtin_path": {
|
|
"description": "Path to 'builtin;' useful for debugging, automatically set if let null",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"zig_lib_path": {
|
|
"description": "Zig library path, e.g. `/path/to/zig/lib/zig`, used to analyze std library imports",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"zig_exe_path": {
|
|
"description": "Zig executable path, e.g. `/path/to/zig/zig`, used to run the custom build runner. If `null`, zig is looked up in `PATH`. Will be used to infer the zig standard library path if none is provided",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"build_runner_path": {
|
|
"description": "Path to the `build_runner.zig` file provided by zls. null is equivalent to `${executable_directory}/build_runner.zig`",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"global_cache_path": {
|
|
"description": "Path to a directory that will be used as zig's cache. null is equivalent to `${KnownFolders.Cache}/zls`",
|
|
"type": "string",
|
|
"default": "null"
|
|
},
|
|
"build_runner_global_cache_path": {
|
|
"description": "Path to a directory that will be used as the global cache path when executing a projects build.zig. null is equivalent to the path shown by `zig env`",
|
|
"type": "string",
|
|
"default": "null"
|
|
}
|
|
}
|
|
}
|