Shutdown correctly LSPs (wait for shudown response).
Allow LSPs definition to declare dynamic vars that can run external commands to set the vars.
Added AdeptLSP support (SpartanJ/ecode#157).
This commit is contained in:
Martín Lucas Golini
2024-03-08 23:02:59 -03:00
parent 5d7d31c236
commit 70c1c4daa5
8 changed files with 53 additions and 7 deletions

View File

@@ -1037,6 +1037,13 @@ void LSPClientPlugin::loadLSPConfig( std::vector<LSPDefinition>& lsps, const std
lsp.host = obj.value( "host", "" );
lsp.port = obj.value( "port", 0 );
lsp.shareProcessWithOtherDefinition = obj.value( "share_process", false );
if ( obj.contains( "vars" ) && obj.is_object() ) {
auto vars = obj["vars"];
for ( const auto& var : vars.items() ) {
if ( var.value().is_string() )
lsp.cmdVars[var.key()] = var.value().get<std::string>();
}
}
}
lsp.commandParameters = obj.value( "command_parameters", lsp.commandParameters );