← Back to all sparks
T

typst-gather

ANALYTICS
Velocity0.0

tool for caching all typst dependencies `@preview` and `@local` for offline use

Extracted from Quarto's CLI, typst-gather learned to explain a dependency tree before fetching it.

typsthermetic-buildsrustcli-toolingdependency-analysis
Current state
typst-gather collects Typst packages into a local cache so documents build offline and hermetically. It was extracted from quarto-cli and reached CRAN-equivalent shape in three releases over a single day, then added an `analyze` subcommand that walks `@Preview` and `@Local` imports — following transitive dependencies of local packages — and prints structured JSON without downloading or copying anything.
Where it's heading
The 0.2.0 restructuring is the tell: subcommands with backwards compatibility, config readable from stdin, and every diagnostic message moved to stderr so stdout carries nothing but JSON. Those are the conventions of a tool meant to be called by another program, not typed by a person. Given its origin inside Quarto's toolchain, the plausible consumer is a build system that needs to know a document's package requirements before deciding what to fetch.
Prediction
The analyze path currently reports imports; the natural extension visible from here is acting on that report — lockfile output or verification that a cache satisfies a document's dependency set — though the entries do not commit to either.

Recent moves

  1. 5mo ago

    analyze subcommand reports the import graph as JSON

    ⚡ SPARK

    Turns a fetcher into an inspector. The `analyze` subcommand resolves the full import graph, including transitive `@Local` dependencies, and emits JSON without touching the network — which is what lets a build system reason about a document's requirements before committing to a download.

    View source ↗
  2. 5mo ago

    Windows path escaping fix and README expansion

    CI repair plus documentation — Windows temp paths containing `\U` were being parsed as TOML unicode escapes in tests. The README now documents the `@Preview` and `@Local` workflows on equal footing with a cache layout diagram.

    View source ↗
  3. 5mo ago

    Split out of quarto-cli as a standalone package gatherer

    The origin release: package-gathering for offline and hermetic Typst builds, extracted from quarto-cli into its own tool. Standing the capability up separately is what made the later analyze work possible as a general-purpose interface rather than a Quarto internal.

    View source ↗