Skip to content

agent-hub-sandbox CLI

agent-hub-sandbox is a minimal Node.js CLI used to exercise the agent-hub autonomous workflow end-to-end (intake → slice → docs) on a small, unambiguous feature. It has no real end users — treat it as a test fixture, not a product.

  • src/cli.js exports run(argv, stdout), a pure function that parses args and writes to the given stdout stream. Kept separate from bin/ so it’s testable without spawning a subprocess.
  • bin/cli.js is the executable entry point: wires process.argv.slice(2), process.stdout, and process.exit to run().
  • --version writes 1.0.0\n and exits 0. The version string is a literal constant in src/cli.js, not read from package.json.
  • Any other invocation (no args, unknown flags) prints nothing and exits 0.
  • src/cli.test.js — unit tests calling run() directly.
  • src/cli.integration.test.js — spawns bin/cli.js as a subprocess to verify the real entry point.
  • Run both with node --test from the repo root.