internal override LSP.Implementation.LanguageClient CreateClient() { #if true string logFilename = @"D:\temp\LSP-Server\lsp_server_response_lua.txt"; var sumnekoLuaLanguageServer = Environment.ExpandEnvironmentVariables(@"%HOMEDRIVE%%HOMEPATH%\AppData\Local\vim-lsp-settings\servers\sumneko-lua-language-server\"); var FileName = "cmd"; var serverCmd = Path.Combine(sumnekoLuaLanguageServer, @"sumneko-lua-language-server.cmd"); var Arguments = String.Format(@"/c ""{0}""", serverCmd); var WorkingDirectory = ""; #endif var client = new LSP.Implementation.LanguageClient(); client.Start(new LSP.Implementation.LanguageClient.LspParameter { exeFileName = FileName, exeArguments = Arguments, exeWorkingDirectory = WorkingDirectory, logger = new Logger(logFilename), jsonWorkspaceConfiguration = workspaceConfig }); return(client); }
internal override LSP.Implementation.LanguageClient CreateClient() { string logFilename = Environment.ExpandEnvironmentVariables(@"D:\temp\LSP-Server\lsp_server_response_vim.txt"); //OK var FileName = @"cmd"; var vimLanguageServerCmd = Environment.ExpandEnvironmentVariables(@"%HOMEDRIVE%%HOMEPATH%\AppData\Local\vim-lsp-settings\servers\vim-language-server\vim-language-server.cmd"); var Arguments = string.Format("/c\"{0}\" --stdio", vimLanguageServerCmd); var WorkingDirectory = rootUri.AbsolutePath; var client = new LSP.Implementation.LanguageClient(); client.Start( new LSP.Implementation.LanguageClient.LspParameter { exeFileName = FileName, exeArguments = Arguments, exeWorkingDirectory = WorkingDirectory, logger = new Logger(logFilename) } ); return client; }
internal override LSP.Implementation.LanguageClient CreateClient() { #if false //OK string logFilename = @"D:\temp\LSP-Server\lsp_server_response_clangd.txt"; var FileName = Environment.ExpandEnvironmentVariables(@"%HOMEDRIVE%%HOMEPATH%\AppData\Local\vim-lsp-settings\servers\clangd\clangd.exe"); var Arguments = @""; var WorkingDirectory = @""; #elif true //OK string logFilename = @"D:\temp\LSP-Server\lsp_server_response_clangd.txt"; var FileName = @"C:\Program Files\LLVM\bin\clangd.exe"; var Arguments = @"";//@"--log=verbose"; var WorkingDirectory = System.IO.Path.GetDirectoryName(sourceUri.AbsolutePath); #elif false //NG /* * cpptools.exeの子プロセスとしてcpptools-srv.exe が起動していないためLSPとして動作しないようだ。 */ string logFilename = @"D:\temp\LSP-Server\lsp_server_response_cpptools.txt"; var FileName = Environment.ExpandEnvironmentVariables(@"%HOMEDRIVE%%HOMEPATH%\.vscode\extensions\ms-vscode.cpptools-1.3.1\bin\cpptools.exe"); var Arguments = @""; var WorkingDirectory = rootPath; #endif var client = new LSP.Implementation.LanguageClient(); client.Start( new LSP.Implementation.LanguageClient.LspParameter { exeFileName = FileName, exeArguments = Arguments, exeWorkingDirectory = WorkingDirectory, logger = new Logger(logFilename) } ); return(client); }