@hstm-labs/forge-cli
v0.3.8
Published
Command-line interface for Forge — built with Commander.js, providing interactive workspace initialization, pipeline execution, compliance verification, output delivery, and run status reporting.
Readme
@hstm-labs/forge-cli
Command-line interface for Forge — built with Commander.js, providing interactive workspace initialization, pipeline execution, compliance verification, output delivery, and run status reporting.
Installation
npm install -g @hstm-labs/forge-cliCommands
forge init [name] # Initialize a new Forge workspace
forge generate # Run the generation pipeline
forge verify # Verify compliance against specification
forge deliver # Package and deliver output
forge status [runId] # Show run status and benchmarksGlobal Options
--json— machine-readable JSON output--quiet— suppress non-essential output--verbose— enable debug logging--no-color— disable terminal colors--no-input— disable interactive prompts (CI mode)
Init Options
--mode=api|agent— set the default execution mode (stored inforge.config.jsonasdefaultMode)
Generate Options
--mode=api|agent— execution mode; when provided, updates the stored default for future runs--stage=<name>— run a specific stage only--continue— resume an AWAITING_AGENT run--resume— resume a failed run--benchmark— enable performance benchmarking
Public API
createProgram()— create the Commander.js program instanceformatSuccess(),formatError(),formatWarning(),formatInfo()— styled output helpersprintJson()— JSON output for--jsonmodehandleError()— structured error handlerGlobalOptions— global option types
Usage
import { createProgram } from '@hstm-labs/forge-cli';
const program = createProgram();
await program.parseAsync(process.argv);