import type { JsonObj } from '../result.js'; import { BaseCommand } from '../index.js'; import { GiteaTokenResponse } from '../util/gitea-api.js'; import { runPush, type GiteaTokenMintResult } from '../push/run-push.js'; export default class Push extends BaseCommand { static description: string; static examples: string[]; static flags: { dir: import("@oclif/core/lib/interfaces/parser.js").OptionFlag; workspace: import("@oclif/core/lib/interfaces/parser.js").OptionFlag; yes: import("@oclif/core/lib/interfaces/parser.js").BooleanFlag; 'skip-validate': import("@oclif/core/lib/interfaces/parser.js").BooleanFlag; 'no-pin-write': import("@oclif/core/lib/interfaces/parser.js").BooleanFlag; message: import("@oclif/core/lib/interfaces/parser.js").OptionFlag; }; run(): Promise; } /** * Map a raw `gitea.token` API response into the `GiteaTokenMintResult` shape * the push core (`runPush`) consumes. Kept as a pure function so we can unit * test the wiring without a network — specifically, to regression-test that * `workspaceId` on the result is the UUID the server returned, not the slug. * * The bug this guards against: before the backend started returning * `workspaceId`, this module used `resp.workspaceSlug` as the `workspaceId` * field, which caused `checkIdentity` to fail when the user passed * `--workspace ` (requested=UUID, backend.workspaceId=slug → mismatch). */ export declare function giteaResponseToMintResult(resp: GiteaTokenResponse): GiteaTokenMintResult; /** * Wire the real implementations of every dependency runPush needs. Kept in * the command file so the pure core stays free of oclif / git shell imports. * * Returns a `{deps, cleanup}` pair. The caller MUST call `cleanup()` in a * finally block so the bare-path probe clone is removed even on errors. * * As of qfg-azk.13 the push code path no longer mints a write-scoped Gitea * token; the actual commit is performed server-side by the `configs.push` * oRPC procedure. We still mint a READ token to authenticate the bare-path * probe-clone and the clone-path `git fetch`. */ export declare function buildRealDeps(cmd: Push, orgSlug: string): { deps: Parameters[1]; cleanup: () => Promise; };