CLI

Site commands search upward from the current working directory for tola.toml. Pass -C to target a config file elsewhere:

sh
tola inspect -C ../docs-site/tola.toml config

Commands

CommandPurpose
tola devStart the local dev server, watch files, and rebuild on change.
tola checkCompile and validate output paths and internal links without writing public/.
tola previewBuild once with production settings in memory and serve locally.
tola buildWrite the verified output atomically to publish-dir (default public/).
tola fmtFormat site Typst sources per [formatter] (--check verifies formatting only).
tola doctorInspect config, paths, hooks, and external tools on this machine.

Dev server

sh
tola dev              # Listen on 127.0.0.1:5277 by default
tola dev --port 0     # Pick an available port automatically
tola dev --no-reuse   # Re-run all hooks on every rebuild
tola dev --json       # Emit one JSON event per line on stdout

When a rebuild fails, tola dev keeps serving the last successful build and prints full diagnostics in the terminal. External wrappers can watch tola dev --json for server-ready, build-finished, and hook-finished events (parse in Nu with lines | each {|line| $line | from json }).

Check and build

sh
tola check --no-hooks               # Skip hooks and reuse existing files on disk
tola check --no-build               # Check standalone Typst syntax only
tola check --json --pretty          # Emit JSON with pages, routes, references, and diagnostics
tola preview --base-path /docs/     # Override base-path for one local preview
tola build -o public-review         # Write to an alternate directory inside the project

Troubleshooting

Run read-only inspect commands to diagnose missing pages, merged config, fonts, or icons:

SymptomCommandLikely cause
New page missingtola inspect sourcesExtension is not lowercase .typ, under a hidden directory or symlink, or filtered by draft: true.
Unexpected config or hook ordertola inspect config --mode devinclude merge precedence, or hook dev / enabled-by settings.
Missing SVG/PDF glyphstola inspect fontsFont missing from [typst.fonts], or system fonts disabled by --pure.
Icon lookup errortola inspect iconsMisspelled collection name, or missing icon.with(module: get-module().name) inside a module.
External tool failuretola doctorHook binary missing from PATH, or invalid directory configuration.

All inspect subcommands accept --json (with --pretty). Add -v, -vv, or --log-file debug.log for detailed execution traces.

Editor & LSP

Tola ships a site-aware Typst language server (tola lsp) and embedded Nushell language server (tola nu --lsp) for completion, hover docs, go-to-definition, rename, and live diagnostics.

sh
tola editor setup --list
tola editor setup vscode --dry-run
tola editor setup vscode
  • tola editor setup <editor> generates package stubs and merges workspace config (e.g. vscode, helix) without overwriting unrelated settings.
  • Add --nu (such as tola editor setup helix --nu) to enable the embedded Nushell LSP alongside Typst.
  • Run tola editor packages after upgrading Tola to refresh editor stubs for @tola/* and modules.
  • Other LSP-capable editors can print a starter snippet with tola editor template <editor> or launch tola lsp directly (falls back to default config if no tola.toml is found).
  • tola fmt and tola lsp share the [formatter] settings in tola.toml.

More commands

  • tola help / tola help -i: Offline terminal reference and interactive browser (see Reference).
  • tola skill --list: Task-oriented guides in the terminal or exported to Markdown.
  • tola <alias> --help: Subcommands registered by configured modules (for instance tola docs guide).
  • tola query: Run named module queries or extract #metadata(...) from standalone .typ files.
  • tola nu: Run scripts with embedded Nushell or call @tola-scripts/*.
  • tola update / tola vendor: Update tola.lock and bundle offline dependencies.
  • tola module check / tola module pack: Validate and package standalone modules.
  • tola completions / tola manpage: Generate shell completions and man pages.

Search this site

Use the arrow keys to move through results.

Type to search.