Documentation

Editor support

Walnut includes a language server in the CLI (walnut lsp) and a VS Code / Cursor extension for .walnut files.

Prerequisites

Install the toolchain (homebrew.md) so walnut is on your PATH:

brew tap franckverrot/walnut
brew install walnut
which walnut

Language server

Editors talk to walnut lsp over stdio. In VS Code / Cursor, set walnut.lsp.path only if the binary is not on PATH.

Confirm it starts:

walnut lsp
# Ctrl-C to stop

Extension

Install the Walnut extension from the marketplace when available, or from a .vsix provided with your toolchain distribution.

After install, open a project with walnut.json / walnut.toml and src/**/*.walnut. Language mode on .walnut files should be Walnut.

What you get

  • Syntax highlighting
  • Diagnostics from the typechecker
  • Hover, go-to-definition, symbols, and completion via LSP