LSP client (lsp/client.rs): - JSON-RPC framing over subprocess stdio - Async request/response with oneshot channels - Background read loop routing responses to pending requests - 30s timeout per request, graceful shutdown LSP manager (lsp/manager.rs): - Auto-detect: Cargo.toml → rust-analyzer, package.json → tsserver, pyproject.toml → pyright, go.mod → gopls - Initialize handshake, lazy textDocument/didOpen - High-level methods: definition, references, hover, document_symbols, workspace_symbols - Graceful degradation when binary not on PATH LSP tools (tools.rs): - lsp_definition, lsp_references, lsp_hover, lsp_diagnostics, lsp_symbols - execute_lsp() async dispatch, is_lsp_tool() check - All routed as ToolSide::Client in orchestrator Tool schemas registered in Sol's build_tool_definitions() for Mistral. Integration tests (6 new): - Language detection for Rust project - is_lsp_tool routing - LSP initialize + hover on src/main.rs - Document symbols (finds main function) - Workspace symbols with retry (waits for rust-analyzer indexing) - Graceful degradation with bad project path
41 lines
992 B
TOML
41 lines
992 B
TOML
[package]
|
|
name = "sunbeam"
|
|
version = "1.0.1"
|
|
edition = "2024"
|
|
description = "Sunbeam local dev stack manager"
|
|
|
|
[[bin]]
|
|
name = "sunbeam"
|
|
path = "src/main.rs"
|
|
|
|
[dependencies]
|
|
sunbeam-sdk = { path = "../sunbeam-sdk", features = ["all", "cli"] }
|
|
sunbeam-proto = { path = "../sunbeam-proto" }
|
|
tokio = { version = "1", features = ["full"] }
|
|
tokio-stream = "0.1"
|
|
clap = { version = "4", features = ["derive"] }
|
|
chrono = "0.4"
|
|
tracing = "0.1"
|
|
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
|
|
rustls = { version = "0.23", features = ["ring"] }
|
|
tonic = "0.14"
|
|
ratatui = "0.29"
|
|
crossterm = "0.28"
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
toml = "0.8"
|
|
anyhow = "1"
|
|
futures = "0.3"
|
|
crossbeam-channel = "0.5"
|
|
textwrap = "0.16"
|
|
tui-markdown = "=0.3.6"
|
|
tree-sitter = "0.24"
|
|
tree-sitter-rust = "0.23"
|
|
tree-sitter-typescript = "0.23"
|
|
tree-sitter-python = "0.23"
|
|
lsp-types = "0.97"
|
|
url = "2"
|
|
|
|
[dev-dependencies]
|
|
tokio-stream = { version = "0.1", features = ["net"] }
|