aboutsummaryrefslogtreecommitdiff
path: root/src/server
diff options
context:
space:
mode:
Diffstat (limited to 'src/server')
-rw-r--r--src/server/requests.odin23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/server/requests.odin b/src/server/requests.odin
index 8af1141..0fd73ba 100644
--- a/src/server/requests.odin
+++ b/src/server/requests.odin
@@ -477,23 +477,22 @@ read_ols_initialize_options :: proc(
)
}
}
+
+ config.profile.os = strings.clone(profile.os)
+
+ break
}
}
+ if config.profile.os == "" {
+ config.profile.os = os_enum_to_string[ODIN_OS]
+ }
+
config.checker_targets = slice.clone(
ols_config.checker_targets,
context.allocator,
)
- found_target := false
-
- for target in config.checker_targets {
- if ODIN_OS in os_enum_to_string {
- found_target = true
- }
- }
-
-
config.enable_inlay_hints =
ols_config.enable_inlay_hints.(bool) or_else config.enable_inlay_hints
config.enable_fake_method =
@@ -558,7 +557,9 @@ read_ols_initialize_options :: proc(
context.temp_allocator,
)
- config.collections[strings.clone(it.name)] = strings.clone(slashed_path)
+ config.collections[strings.clone(it.name)] = strings.clone(
+ slashed_path,
+ )
} else {
log.errorf(
"Failed to find absolute address of collection: %v",
@@ -743,7 +744,7 @@ request_initialize :: proc(
if uri, ok := common.parse_uri(project_uri, context.temp_allocator); ok {
global_ols_config_path := path.join(
- elems = {
+ elems = {
filepath.dir(os.args[0], context.temp_allocator),
"ols.json",
},