UNPKG

@code-yeongyu/senpi

Version:

Coding agent CLI with read, bash, edit, write tools and session management

22 lines • 1.26 kB
import type { RepositoryMatch } from "../core/repository-identity.ts"; export type CrossProjectAction = "rebind" | "fork" | "abort" | "fail"; export declare const FORK_PROMPT = "Fork this session into current directory?"; export declare const REBIND_PROMPT = "Move this session here and continue it?"; export interface CrossProjectChoice { readonly sessionArg: string; readonly sessionCwd: string; readonly cwd: string; readonly match: RepositoryMatch; readonly interactive: boolean; readonly confirm: (message: string) => Promise<boolean>; readonly out: (line: string) => void; readonly err: (line: string) => void; } /** * Decides what `--session <id>` does with a session recorded under another project path. The same * repository offers a rebind; a different or unrecognised one keeps the fork prompt. Without an * interactive session nothing is asked: the exact commands are printed and the caller exits non-zero. */ export declare function chooseCrossProjectAction(choice: CrossProjectChoice): Promise<CrossProjectAction>; export declare function confirmSameRepositoryRebind(choice: Pick<CrossProjectChoice, "sessionArg" | "cwd" | "confirm" | "out">): Promise<boolean>; //# sourceMappingURL=cross-project-session.d.ts.map