function run
run(): Promise<number>

Dispatches qunitx daemon <subcommand>. _serve runs the in-process daemon loop (spawned by start); all other subcommands are client operations. No subcommand (or --help / -h / help) prints usage and exits 0; an unknown subcommand prints usage to stderr and exits 1.

// Defined, not invoked: dispatches on live process.argv and may spawn the daemon.
async function daemonCommand(): Promise<number> {
  return await run(); // `qunitx daemon status` → exit code
}

Return Type

Promise<number>

Usage

import { run } from "lib/commands/daemon/index.ts";