wirer

Crates.iowirer
lib.rswirer
version0.1.0
created_at2026-01-14 04:01:57.963324+00
updated_at2026-01-14 04:01:57.963324+00
descriptionMinimal CLI to inspect, resolve, compose, and run FROST components.
homepage
repositoryhttps://github.com/RAKUDEJI/FROST
max_upload_size
id2042122
size201,201
Kentaro Maeda (EFEXP)

documentation

README

wirer

Minimal CLI that inspects component imports, resolves providers from a catalog, composes a single component, and runs job components via sdk/rust/host (crate: frost-host-sdk).

wirer.toml (minimal)

[app]
name = "job-hello"
kind = "job"                # "job" | "service"
component = "dist/job-hello.component.wasm"
composed = "dist/job-hello.composed.component.wasm"

[compose]
catalog = "components/reference/catalog.json"
output = "dist/job-hello.composed.component.wasm"
lock = ".wirer/wirer.lock.json"
allow_frost_imports = ["frost:core/context", "frost:core/types"]

[dev]
build_cmd = ["make", "build-job-hello"]
watch = ["apps/job-hello/guest/src", "apps/job-hello/guest/wit"]
debounce_ms = 400

catalog.json (minimal)

{
  "providers": [
    {
      "name": "kernel-core-diagnostics-stdout",
      "path": "components/reference/providers/kernel-core-diagnostics-stdout/dist/kernel-core-diagnostics-stdout.component.wasm",
      "exports": ["frost:core/diagnostics"]
    }
  ]
}

Commands

cargo run --manifest-path tools/wirer/Cargo.toml -- inspect --component dist/app.component.wasm
cargo run --manifest-path tools/wirer/Cargo.toml -- resolve --catalog components/reference/catalog.json
cargo run --manifest-path tools/wirer/Cargo.toml -- compose --catalog components/reference/catalog.json
cargo run --manifest-path tools/wirer/Cargo.toml -- run --component dist/app.composed.component.wasm
cargo run --manifest-path tools/wirer/Cargo.toml -- dev --once --catalog components/reference/catalog.json --build-cmd make,build-job-hello
cargo run --manifest-path tools/wirer/Cargo.toml -- deps --wit-dir wit --lock wit/wkg.lock --output wit
cargo run --manifest-path tools/wirer/Cargo.toml -- componentize --core dist/app.core.wasm --wit-dir wit --world runtime --output dist/app.component.wasm
cargo run --manifest-path tools/wirer/Cargo.toml -- wit --component dist/app.component.wasm --output dist/app.wit

Notes:

  • compose validates that no unexpected frost:* imports remain (only frost:core/context and frost:core/types are allowed by default).
  • run currently supports kind = "job" only.
  • deps reads wkg.toml from --wit-dir unless --wkg-config is provided.
  • dev watches configured paths, optionally runs build_cmd, then composes and runs on changes.

cargo-generate templates

cargo generate --path tools/wirer/templates/guest-job --name job-hello --destination apps
cargo generate --path tools/wirer/templates/guest-service --name svc-hello --destination apps

This creates apps/<name>/guest with wirer.toml, WIT files, and a minimal Makefile.

Commit count: 0

cargo fmt