Editor setup
Editor setup
Section titled “Editor setup”Axel ships editor extensions for Zed and VS Code. Each provides syntax highlighting
plus a language server — live diagnostics, hover, go-to-definition, and completion — for .asl
schemas and .aql queries.
Prerequisites
Section titled “Prerequisites”The language server is the axel CLI (axel lsp), so both editors need axel installed and
on your PATH. Install it first (see Installation) and verify:
axel versionIf axel isn’t found, syntax highlighting still works, but the language-server features won’t
start (the extension shows a “not found” notice).
Both extensions live in the Axel repo under tools/, so clone it:
git clone https://github.com/struckchure/axel.gitcd axelZed installs the extension from a local directory as a dev extension and compiles it on install: the tree-sitter grammars and the Rust language-server shim. You need a Rust toolchain (Zed adds the wasm target itself).
- Open the command palette (
cmd-shift-p) and runzed: install dev extension. - Select the
tools/zeddirectory in your Axel checkout. - Open a
.aslor.aqlfile — highlighting and LSP features activate automatically.
To use a specific axel binary instead of the one on PATH, add to your Zed settings.json:
{ "lsp": { "axel": { "binary": { "path": "/absolute/path/to/axel" } } } }More detail: tools/zed/README.md.
VS Code
Section titled “VS Code”Build a .vsix and install it with the code CLI. Requires Bun.
cd tools/vscodebun installbun run package # produces axel-<version>.vsixcode --install-extension axel-*.vsixReload VS Code, then open a .asl or .aql file.
To use a specific axel binary, set it in Settings (axel.path):
{ "axel.path": "/absolute/path/to/axel" }Developing the extension: open the tools/vscode folder in VS Code and press F5 to launch
an Extension Development Host with the extension loaded; after editing the source, re-run
bun run package and reinstall. Use the Axel: Restart Language Server command to reconnect
after installing or updating axel.
More detail: tools/vscode/README.md.
What you get
Section titled “What you get”- Syntax highlighting for
.asland.aql. - Diagnostics — live parse/resolve errors for schemas, and parse/compile errors for queries.
- Hover, go-to-definition, and completion, powered by
axel lsp(including full IntelliSense and documentation for AQL built-in directives@name,@request,@response,@rel_load_strategy, and schema directives). - Configuration autocomplete & validation in
axel.yamlvia YAML language server schema integration (# yaml-language-server: $schema=...).
Query files are resolved against your schema via axel.yaml (schema-path) in the workspace
root, so completion and cross-file diagnostics know your types.
When schema-path is a directory or a glob, the language server merges the whole
split schema before resolving it: a type declared in one file is known in every
other, and a problem is reported against the file that owns it.