test rust lsp

This commit is contained in:
2025-09-07 07:18:18 +02:00
parent a8bf55882e
commit 7a3e3ae9f7
330 changed files with 1714 additions and 70094 deletions
+10
View File
@@ -0,0 +1,10 @@
This folder contains debug and task configurations for developing the extension and the Rust language server.
- `launch.json`: Debug configurations for the Extension Host and for the Rust server (expects `CodeLLDB` extension).
- `tasks.json`: Tasks to build the client (`npm run build`) and server (`cargo build`).
Usage:
1. Install the `vadimcn.vscode-lldb` (CodeLLDB) extension for Rust debugging.
2. Run the `npm: build (client)` task or use the Run Extension configuration which will run it as a preLaunchTask.
3. Use `Launch Rust server (CodeLLDB)` to build and run the server under the debugger.
+15 -61
View File
@@ -1,74 +1,28 @@
// A launch configuration that compiles the extension and then opens it inside a new window
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Run Extension",
"type": "extensionHost",
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": ["--extensionDevelopmentPath=${workspaceFolder}"],
"outFiles": ["${workspaceFolder}/client/**/*.js"],
"name": "Run TCL LSP",
"runtimeExecutable": "${execPath}/",
"args": ["--extensionDevelopmentPath=${workspaceFolder}/", "${workspaceFolder}/test/"],
"outFiles": ["${workspaceFolder}/client/out/**/*.js"],
"autoAttachChildProcesses": true,
"preLaunchTask": {
"type": "npm",
"script": "watch"
}
"preLaunchTask": "npm: build"
},
{
"name": "Python Attach",
"type": "debugpy",
"request": "attach",
"processId": "${command:pickProcess}",
"justMyCode": false,
"presentation": {
"hidden": false,
"group": "",
"order": 3
}
},
{
"name": "Debug Extension (hidden)",
"type": "extensionHost",
"name": "Debug Rust LSP Server (debug)",
"type": "lldb",
"request": "launch",
"args": ["--extensionDevelopmentPath=${workspaceFolder}"],
"outFiles": ["${workspaceFolder}/client/**/*.js"],
"env": {
"USE_DEBUGPY": "True"
},
"presentation": {
"hidden": true,
"group": "",
"order": 4
}
},
{
"name": "Python debug server (hidden)",
"type": "debugpy",
"request": "attach",
"listen": { "host": "localhost", "port": 5678 },
"justMyCode": true,
"presentation": {
"hidden": true,
"group": "",
"order": 4
}
}
],
"compounds": [
{
"name": "Debug Extension and Python",
"configurations": ["Python debug server (hidden)", "Debug Extension (hidden)"],
"stopAll": true,
"preLaunchTask": "npm: watch",
"presentation": {
"hidden": false,
"group": "",
"order": 1
}
"program": "${workspaceFolder}/server/target/debug/server.exe",
"args": [],
"env": { "RUST_BACKTRACE": "1" },
"preLaunchTask": "cargo: build server",
"stopOnEntry": true
}
]
}
+11
View File
@@ -0,0 +1,11 @@
{
"version": "2.0.0",
"tasks": [
{
"type": "npm",
"script": "build",
"label": "npm: build",
"path": "./"
}
]
}