Skip to content

runMigrationCommand

runMigrationCommand(command, cwd, options?): MigrationProjectState | MigrationDiff | { verifiedVersions: string[]; } | { checkedVersions: string[]; checks: object[]; } | { generatedVersions: string[]; skippedVersions: string[]; } | { fuzzedVersions: string[]; seed: number | undefined; } | MigrationPlanSummary | Promise<MigrationPlanSummary | { cancelled: true; }> | object[] | { blockName: string; diff: MigrationDiff; rulePath: string; } | { scaffolded: object[]; }

Defined in: wp-typia-project-tools/src/runtime/migrations.ts:109

Dispatch a parsed migration command to the matching runtime workflow.

Most commands execute synchronously and preserve direct throw semantics for existing callers. The interactive wizard command returns a promise because it waits for prompt selection before running the shared read-only planner.

ParsedMigrationArgs

Parsed migration command and flags.

string

Project directory to operate on.

CommandRenderOptions = {}

Optional prompt/render hooks for testable and interactive execution.

MigrationProjectState | MigrationDiff | { verifiedVersions: string[]; } | { checkedVersions: string[]; checks: object[]; } | { generatedVersions: string[]; skippedVersions: string[]; } | { fuzzedVersions: string[]; seed: number | undefined; } | MigrationPlanSummary | Promise<MigrationPlanSummary | { cancelled: true; }> | object[] | { blockName: string; diff: MigrationDiff; rulePath: string; } | { scaffolded: object[]; }

The command result, or a promise when the selected command is interactive.