#!/usr/bin/env npx tsx /** * Options for the release process. */ export interface ReleaseOptions { /** The project directory containing package.json (default: current directory) */ directory?: string; /** The git branch to release from (default: 'main') */ branch?: string; /** If true, simulate the release without making changes (default: false) */ dryRun?: boolean; } /** * Executes the npm release process. * * This function performs a complete release workflow: * 1. Validates git state (correct branch, no uncommitted changes) * 2. Pulls latest changes from remote * 3. Verifies npm authentication * 4. Prompts for new version (with suggestion based on conventional commits) * 5. Runs project checks * 6. Updates package.json version * 7. Updates CHANGELOG.md * 8. Publishes to npm (if not private) * 9. Creates git commit and tag * 10. Pushes to remote and creates GitHub release * * @param directory - The project directory containing package.json * @param branch - The git branch to release from (default: 'main') * @param dryRun - If true, simulate the release without making changes * @throws {VrtError} If any step in the release process fails * * @example * ```ts * // Standard release from main branch * await release('/path/to/project'); * * // Dry run to preview release * await release('/path/to/project', 'main', true); * * // Release from a different branch * await release('/path/to/project', 'release'); * ``` */ export declare function release(directory: string, branch?: string, dryRun?: boolean): Promise;