/** * @fileoverview Mode helpers for the `fit` Commander action. * * The `fit` subcommand dispatches to one of five mutually exclusive * modes (gate, list, recipes, json, live) based on the parsed flags. * Each mode is small and self-contained; isolating them in this module * keeps `tool.ts` focused on Commander wiring and lets the runner * branches be tested independently. * * The exported helpers all take the Commander-parsed `FitOptions` plus * the `ToolCliContext` the dispatcher provides to each tool. */ import { type FitOptions } from '@opensip-cli/contracts'; import { type ToolCliContext, type ToolRunCompletion } from '@opensip-cli/core'; /** * The portion of a {@link ToolRunCompletion} fit's static modes return: the * generic-session contribution (host-owned-run-timing Phase 3). The host run * plane persists it after the handler resolves; the tool writes nothing itself. */ type FitRunCompletion = Pick; export declare function runListMode(args: FitOptions, cli: ToolCliContext): Promise; export declare function runRecipesMode(args: FitOptions, cli: ToolCliContext): Promise; export declare function runShowMode(args: FitOptions, cli: ToolCliContext): Promise; /** * `--json` mode: run executeFit, write output (or error) to stdout, and * propagate the configured fail threshold via the CLI's exit-code hook. * * Threads `datastore` so a `--json` run lands in the SQLite session * history alongside live-mode and gate-mode runs. No `onProgress`: JSON * output is one-shot, no progress UI. */ export declare function runJsonMode(args: FitOptions, cli: ToolCliContext): Promise; /** * Visual mode — Ink-rendered live results. The CLI supplies the * renderer via `cli.renderLive()` so this file doesn't depend on the * CLI package directly. After the run, optionally launches the HTML * dashboard. */ export declare function runLiveMode(args: FitOptions, cli: ToolCliContext, liveViewKey: string, openRequested: boolean): Promise; export declare function runGateMode(args: FitOptions, cli: ToolCliContext): Promise; export {}; //# sourceMappingURL=fit-modes.d.ts.map