From 0444574ea13ac11609b430da874c087360613199 Mon Sep 17 00:00:00 2001 From: Konstantin Fickel Date: Sun, 19 Apr 2026 20:54:11 +0200 Subject: [PATCH] docs: expand Neovim LSP setup with step-by-step guide and keymaps --- README.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/README.md b/README.md index a04e0ce..ccc00c5 100644 --- a/README.md +++ b/README.md @@ -155,6 +155,8 @@ The `"..."` keeps Zed's default Markdown servers (e.g. `marksman`) active alongs ### Neovim (nvim-lspconfig) +**1. Register the server** — add to your Neovim config (e.g. `~/.config/nvim/init.lua` or a plugin file): + ```lua local lspconfig = require('lspconfig') local configs = require('lspconfig.configs') @@ -173,6 +175,23 @@ end lspconfig.streamd.setup {} ``` +The server activates automatically when Neovim opens a Markdown file inside a directory that contains a `.streamd.toml` file. + +**2. Using LSP features** — standard Neovim LSP keymaps apply (`:help lsp`): + +| Action | Default keymap | Notes | +|---|---|---| +| Trigger `@` completions | `` (insert mode) | Or via your completion plugin (`nvim-cmp`, `blink.cmp`, …) | +| Show diagnostics for current line | `d` / `gl` | File-name format warnings, timesheet errors | +| Jump to next / previous diagnostic | `]d` / `[d` | Navigate between warnings | +| Code actions (mark task as done) | `ca` (Neovim ≥ 0.10) | Place cursor on a line with `@Task` | +| Rename marker across all files | `cr` / `grn` | Renames the `@Marker` under the cursor everywhere | +| Find all references to a marker | `grr` / `fr` | Lists every occurrence of `@Marker` across the workspace | +| Document outline (shard tree) | `:lua vim.lsp.buf.document_symbol()` | Or via Telescope: `:Telescope lsp_document_symbols` | +| Workspace symbol search | `:lua vim.lsp.buf.workspace_symbol()` | Or via Telescope: `:Telescope lsp_workspace_symbols` | + +> **Note:** default keymaps (`grn`, `grr`, `d`, `]d`/`[d`) are available from Neovim 0.10+. On older versions use `:lua vim.lsp.buf.*` commands or set up keymaps manually in your `on_attach` callback. + ### VS Code (tasks.json / manual) Use any extension that lets you configure custom LSP servers, pointing `cmd` to `streamd lsp`.