Language server (tish-lsp)
Install tish-lsp, LSP capabilities, editor examples, and troubleshooting.
tish-lsp implements the Language Server Protocol for Tish. One binary powers VS Code, Cursor, Neovim, Zed, Helix, and any LSP-aware editor.
Install
From the Tish repository:
cargo build --release -p tish_lsp
# Install on PATH, e.g.:
cp target/release/tish-lsp ~/.local/bin/Stdin/stdout: the server speaks LSP over stdio. Do not run it interactively expecting a prompt; editors spawn it as a child process.
Environment
No required environment variables. Optional:
Exit codes
The server runs until the client disconnects. Normal exit is 0. Startup failures may surface in the editor’s LSP log.
Capabilities (current)
Not yet: rename, hover types, semantic tokens, code actions, multi-root import graph for bare specifiers.
CLI contract
- Command:
tish-lsp - Arguments: none
- Transport: JSON-RPC on stdio
- CI: use standalone
tish-fmt --checkandtish-lint(not thetishcompiler).
Editor examples
VS Code / Cursor
Use the Tish extension; it starts tish-lsp by default. Override with tish.languageServerPath.
Neovim
See Editor and IDE setup for an nvim-lspconfig snippet.
Helix (illustrative)
# languages.toml (conceptual — adjust to your Helix version)
[[language]]
name = "tish"
language-servers = ["tish-lsp"]
[language-server.tish-lsp]
command = "tish-lsp"Troubleshooting
- Output panel — VS Code: set
tish.trace.servertoverbose, then View → Output → Tish Language Server. - Workspace folder — open the project directory so
workspace/symboland import resolution see files on disk. - Canonical paths — go-to-definition on imports uses resolved filesystem paths; unsaved buffers only work for same-file navigation.
Contributing
See the Tish repo docs/tooling.md and crates/tish_lsp/README.md for how to extend the server (new LSP methods, tests).