feat: add streamd lsp subcommand with LSP server #90

Merged
kfickel merged 12 commits from 89_streamd-lsp-subcommand into main 2026-04-19 21:18:45 +02:00

12 commits

Author SHA1 Message Date
82adb655f1
feat: add Zed extension release artifact with WSL2 support
All checks were successful
Continuous Integration / Build Package (push) Successful in 30s
Continuous Integration / Lint, Check & Test (push) Successful in 1m9s
Release / Build and Release (push) Successful in 7m10s
The Zed extension now detects Windows via current_platform() and
automatically uses `wsl streamd lsp` instead of `streamd lsp`,
enabling seamless LSP support when Zed runs on Windows with streamd
installed in WSL2.

A pre-built zip (extension.toml + extension.wasm) is now built as
`zed-extension-zip` and published to every release. The README gains
a step-by-step WSL2 installation guide.
2026-04-19 21:16:04 +02:00
ec978590c0
feat: add clippy and cargo test as dev pre-commit hooks
Splits git hooks into two configurations: a sandbox-safe set for
`nix flake check` (rustfmt + commitizen) and a full dev set installed
via `nix develop` that also runs clippy (deny warnings) and cargo test.
2026-04-19 21:15:51 +02:00
8e69a6afe8
fix: fix clippy
All checks were successful
Continuous Integration / Lint, Check & Test (push) Successful in 1m40s
Continuous Integration / Build Package (push) Successful in 2m18s
2026-04-19 21:07:30 +02:00
43ec0a56de
fix: fix timestamp insertion
Some checks failed
Continuous Integration / Lint, Check & Test (push) Failing after 1m34s
Continuous Integration / Build Package (push) Successful in 3m22s
2026-04-19 21:02:52 +02:00
073a04c337
fix: use actual timestamps for completion 2026-04-19 21:02:51 +02:00
61c4c00a57
docs: expand Neovim LSP setup with step-by-step guide and keymaps 2026-04-19 21:02:50 +02:00
2307891d0d
fix: fix lsp adding two @ 2026-04-19 21:02:49 +02:00
76a1a6b695
feat: add zed extension 2026-04-19 21:02:48 +02:00
dbf0808233
fix(daily): use midnight when creating file for non-today date 2026-04-19 21:02:47 +02:00
5c6a88a211
refactor: simplify LSP implementation
- Extract find_pattern_occurrences_in_lines helper; use in both references and rename handlers (deduplicates word-boundary search logic)
- Add MD_EXT constant to replace three repeated "md" string literals
- Fix double lock acquire/drop/re-acquire in code_action (use single guard)
- Fix symbol() to populate file_lines cache when parsing from disk (avoids redundant re-reads on subsequent requests)
- Remove section separator comment blocks (code structure is self-evident from Rust syntax)
2026-04-19 21:02:46 +02:00
d0316e8dac
fix: resolve clippy warnings in lsp module
- Replace map_or(false, ...) with is_none_or(... !=)
- Replace explicit auto-derefs (&*Static) with auto-deref (&Static)
- Refactor range-indexed loop to iterator with enumerate + skip/take
- Suppress deprecated root_path field with allow(deprecated)

docs: update README and REQUIREMENTS for streamd lsp

- Add streamd lsp to commands table in README
- Add Editor Integration section with Zed, Neovim, VS Code snippets
- Add R25 LSP requirements (R25a–R25e) to REQUIREMENTS.md
2026-04-19 21:02:45 +02:00
448cf31b39
feat: add streamd lsp subcommand with LSP server
Implements a full Language Server Protocol server accessible via
`streamd lsp`. The server communicates over stdin/stdout and auto-
detects the workspace root from the LSP initialize request.

Features implemented:
- Passive mode when no .streamd.toml exists in workspace root
- Workspace-root-based config loading (bypasses R22/R23 global config)
- .streamd.toml file watcher (config reloads without restart)
- textDocument/completion with @ trigger, conditional suggestions
  (if_with relationships), and temporal date/time snippets (R16)
- textDocument/publishDiagnostics: R15 file-name format + R18
  timesheet violations (overlapping timecards, unclosed days)
- textDocument/documentSymbol: shard tree exposed as nested symbols
- textDocument/codeAction: "Mark task as done" quickfix for @Task
- workspace/symbol: cross-file shard search
- textDocument/references: find all @Marker occurrences
- textDocument/rename: rename @Marker across all files

Dependencies added: tower-lsp 0.20, tokio, dashmap, serde_json
2026-04-19 21:02:44 +02:00