agent-afk 5.84.8 → 5.84.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/worktree-orphan-guard.d.ts +14 -0
- package/dist/agent/worktree-sweep.d.ts +1 -1
- package/dist/cli/terminal-compositor.scrollback.d.ts +9 -0
- package/dist/cli/terminal-compositor.types.d.ts +0 -8
- package/dist/cli.mjs +456 -456
- package/dist/index.mjs +161 -161
- package/dist/telegram.mjs +215 -215
- package/package.json +1 -1
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export type OrphanPreserveReason = 'too-young' | 'non-rebuildable-content' | 'scan-failed' | 'scan-budget-exhausted';
|
|
2
|
+
export type OrphanVerdict = {
|
|
3
|
+
remove: true;
|
|
4
|
+
} | {
|
|
5
|
+
remove: false;
|
|
6
|
+
because: OrphanPreserveReason;
|
|
7
|
+
detail?: string;
|
|
8
|
+
};
|
|
9
|
+
export declare const ORPHAN_SCAN_MAX_DEPTH = 8;
|
|
10
|
+
export declare const ORPHAN_SCAN_MAX_ENTRIES = 4000;
|
|
11
|
+
export declare function classifyOrphanDir(orphanPath: string, orphanAgeMs: number, minAgeMs: number, limits?: {
|
|
12
|
+
maxDepth?: number;
|
|
13
|
+
maxEntries?: number;
|
|
14
|
+
}): Promise<OrphanVerdict>;
|
|
@@ -7,7 +7,7 @@ export type ExecFileFn = (file: string, args: string[], opts?: {
|
|
|
7
7
|
stdout: string;
|
|
8
8
|
stderr: string;
|
|
9
9
|
}>;
|
|
10
|
-
type WorktreeVerdict = 'empty' | 'stale-clean' | 'stale-dirty' | 'locked' | 'active' | 'orphaned-dir' | 'orphaned-registration' | 'dead-owner';
|
|
10
|
+
type WorktreeVerdict = 'empty' | 'stale-clean' | 'stale-dirty' | 'locked' | 'active' | 'orphaned-dir' | 'orphaned-dir-preserved' | 'orphaned-registration' | 'dead-owner';
|
|
11
11
|
export interface SweepOptions {
|
|
12
12
|
execFile: ExecFileFn;
|
|
13
13
|
repoRoot: string;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { BandRowMeta } from './terminal-compositor.types.js';
|
|
2
|
+
export declare const ELAPSED_GRACE_MS = 2000;
|
|
3
|
+
export declare function formatElapsed(startedAt: number): string;
|
|
4
|
+
export declare function eraseAndPaintRow(row: number, line?: string): string;
|
|
5
|
+
export declare function buildBandMeta(logicalLines: readonly string[], width: number): BandRowMeta[];
|
|
6
|
+
export declare function scrollbackFlushLines(rows: readonly string[], meta: readonly BandRowMeta[] | undefined, count: number): string[];
|
|
7
|
+
export declare function snapFlushCountToLogicalBoundary(meta: readonly BandRowMeta[] | undefined, count: number, total: number): number;
|
|
8
|
+
export declare function buildScrollbackArchiveEscape(lines: readonly string[], anchorFloor: number, bottomRow: number, width: number): string;
|
|
9
|
+
export declare function formatTipRow(text: string, cols: number): string;
|
|
@@ -23,18 +23,10 @@ export interface KeyInfo {
|
|
|
23
23
|
shift?: boolean;
|
|
24
24
|
}
|
|
25
25
|
export declare const SPINNER_FRAMES: readonly ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"];
|
|
26
|
-
export declare const ELAPSED_GRACE_MS = 2000;
|
|
27
|
-
export declare function formatElapsed(startedAt: number): string;
|
|
28
|
-
export declare function eraseAndPaintRow(row: number, line?: string): string;
|
|
29
26
|
export interface BandRowMeta {
|
|
30
27
|
logicalText: string;
|
|
31
28
|
isHead: boolean;
|
|
32
29
|
}
|
|
33
|
-
export declare function buildBandMeta(logicalLines: readonly string[], width: number): BandRowMeta[];
|
|
34
|
-
export declare function scrollbackFlushLines(rows: readonly string[], meta: readonly BandRowMeta[] | undefined, count: number): string[];
|
|
35
|
-
export declare function snapFlushCountToLogicalBoundary(meta: readonly BandRowMeta[] | undefined, count: number, total: number): number;
|
|
36
|
-
export declare function buildScrollbackArchiveEscape(lines: readonly string[], anchorFloor: number, bottomRow: number, width: number): string;
|
|
37
|
-
export declare function formatTipRow(text: string, cols: number): string;
|
|
38
30
|
export interface SpinnerState {
|
|
39
31
|
frameIndex: number;
|
|
40
32
|
verb: string;
|