/** * Opening a pull or merge request through the forge's own CLI: `gh` for GitHub-style hosts, `glab` * for GitLab-style hosts. It works with any host the CLI is signed in to (github.com, GitHub * Enterprise, gitlab.com, self-hosted GitLab); nothing here knows a host by name beyond a hint to * try the likelier CLI first. */ export type ForgeCli = "gh" | "glab"; export interface PrRequest { base: string; head: string; title: string; body: string; draft: boolean; } /** The CLIs to try for a host, likeliest first. */ export declare function candidateClis(host: string | undefined): ForgeCli[]; /** Arguments (and stdin) that create the request with the given CLI. */ export declare function createArgs(cli: ForgeCli, r: PrRequest): { args: string[]; input?: string; }; /** The first URL in a command's output, if any. */ export declare function findUrl(text: string): string | undefined; /** The first candidate CLI that is installed and signed in for `host`. */ export declare function findForge(cwd: string, host: string | undefined): Promise; export declare function createRequest(cwd: string, cli: ForgeCli, r: PrRequest): Promise;