import { type Argv, type Arguments } from 'yargs'; /** Accepted npm version bump keywords. */ declare const VERSION_TYPES: readonly ['major', 'minor', 'patch', 'prerelease']; export type VersionType = (typeof VERSION_TYPES)[number]; /** * Side-effectful primitives used by the `up` orchestration, extracted behind * an interface so the flow can be unit-tested with fakes. */ export interface UpDeps { /** True if `npm-check-updates` (ncu) is available on PATH. */ ncuAvailable(): boolean; /** Installs `npm-check-updates` globally. */ installNcu(): void; /** Runs `git pull` in the service directory. */ gitPull(dir: string): void; /** Runs `ncu -u` in the service directory. */ ncuUpgrade(dir: string): void; /** Removes `node_modules` and `package-lock.json`. */ removeArtifacts(dir: string): void; /** Runs `npm install` in the service directory. */ npmInstall(dir: string): void; /** True if the working tree has uncommitted changes. */ gitDirty(dir: string): boolean; /** Commits all changes with the given message. */ gitCommit(dir: string, message: string): void; /** Runs `npm version ` in the service directory. */ npmVersion(dir: string, type: VersionType): void; /** Runs `git push --follow-tags`. */ gitPushTags(dir: string): void; /** Writes a status line for the user. */ log(msg: string): void; } /** Options controlling an `up` invocation. */ export interface UpOptions { path: string; services?: string[]; npmVersion: string; commit: boolean; skipUpdate: boolean; } /** * Normalises a version-bump keyword, defaulting anything unrecognised to * `prerelease` (matching the legacy bash behaviour). * * @param {string} type - raw keyword from the CLI * @return {VersionType} */ export declare function normalizeVersionType(type: string): VersionType; /** * Updates dependencies (and optionally version-bumps, commits and pushes) for * every selected service under the given path. * * Each service is processed independently: a step that fails (a thrown dep, * e.g. a non-zero `git pull`) aborts only that service, is recorded, and the * run continues with the next. If any service failed, a summarizing error is * thrown so the caller can report it and exit non-zero. * * @param {UpOptions} opts * @param {UpDeps} deps * @return {void} * @throws {Error} when neither an update nor a commit is requested, when the * ncu bootstrap fails, or when one or more services failed */ export declare function runUp(opts: UpOptions, deps: UpDeps): void; /** * Builds the production dependency set (real spawning and filesystem). * * @return {UpDeps} */ export declare function defaultDeps(): UpDeps; export declare const command: string, describe: string, builder: (yargs: Argv) => Argv<{ p: string; } & { s: string | undefined; } & { v: string; } & { c: boolean; } & { u: boolean; }>, handler: (argv: Arguments) => void; export {};