agent-afk 5.215.1 → 5.216.0

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.
@@ -0,0 +1,13 @@
1
+ export interface CaptureEntry {
2
+ sessionId: string;
3
+ toolUseId: string;
4
+ filePath: string;
5
+ mtimeMs: number;
6
+ sizeBytes: number;
7
+ preview: string;
8
+ }
9
+ export interface ListCapturesOptions {
10
+ sessionId?: string;
11
+ limit?: number;
12
+ }
13
+ export declare function listCaptures(options?: ListCapturesOptions): Promise<CaptureEntry[]>;
@@ -17,7 +17,7 @@ Never — not for a real bug, not for a blocking defect, not even when there is
17
17
  **Exception:** `gh pr merge` is permitted after a **MERGE** verdict on a PR review in-which the findings are docs/test-related only, but **only** after the user explicitly confirms via `ask_question` (see **Merge offer** below).
18
18
  - run any other write- or network-mutating shell command.
19
19
 
20
- The only shell permitted is **read-only inspection**: `git diff` / `git show` / `gh pr diff`, `grep` / `rg`, and file reads — plus dispatching the review sub-agents. Resolving findings, fixing bugs, resolving merge conflicts, and "making the branch mergeable" are explicitly **out of scope**: a fixable defect is a finding to report (`file:line` + a one-line fix in the `suggestion` field), never a license to act.
20
+ The only shell permitted is **read-only inspection**: `git diff` / `git show` / `gh pr diff` / `gh repo view`, `grep` / `rg`, and file reads — plus dispatching the review sub-agents. Resolving findings, fixing bugs, resolving merge conflicts, and "making the branch mergeable" are explicitly **out of scope**: a fixable defect is a finding to report (`file:line` + a one-line fix in the `suggestion` field), never a license to act.
21
21
 
22
22
  ## Sub-agent contract
23
23
  /contract
@@ -144,7 +144,7 @@ State the counts that drove the decision on the same line, **with a dimension br
144
144
 
145
145
  This is the terminal step. A blocking bug is a finding to report, not a fix to apply -- no edits, commits, pushes, or PR/MR mutations.
146
146
 
147
- **Merge offer (docs/test-only PR reviews).** When **all four** hold: (1) the decision is **MERGE**, (2) the review target was a **PR** (URL or number), (3) every surviving finding is in the `test-coverage` dimension or is a documentation-only concern (comments, doc strings, README) -- no `security`, `correctness`, `api-compat`, `perf-observability`, or `spec-compliance` findings survived, and (4) every changed file in the PR is a test or documentation file (test files: `*.test.*`, `*.spec.*`, files under `__tests__/`, `/test/`, `/tests/`; doc files: `*.md`, `*.mdx`, doc-only config such as `typedoc.json`) -- no production source files changed -- ask the user: "Would you like me to merge this PR?" via `ask_question` with `type: "confirm"`. On accept (`value: true`), run `gh pr merge <pr-ref> --squash --match-head-commit <reviewed-ref>` where `<reviewed-ref>` is the SHA captured at triage time, so the merge is pinned to the exact commit that was reviewed. If `gh pr merge` exits non-zero, surface the error output to the user and stop. On decline, cancel, skip, non-PR target, or any condition not met: stop.
147
+ **Merge offer (docs/test-only PR reviews).** When **all four** hold: (1) the decision is **MERGE**, (2) the review target was a **PR** (URL or number), (3) every surviving finding is in the `test-coverage` dimension or is a documentation-only concern (comments, doc strings, README) -- no `security`, `correctness`, `api-compat`, `perf-observability`, or `spec-compliance` findings survived, and (4) every changed file in the PR is a test or documentation file (test files: `*.test.*`, `*.spec.*`, files under `__tests__/`, `/test/`, `/tests/`; doc files: `*.md`, `*.mdx`, doc-only config such as `typedoc.json`) -- no production source files changed -- ask the user: "Would you like me to merge this PR?" via `ask_question` with `type: "confirm"`. On accept (`value: true`), determine the target repo's preferred merge strategy via `gh repo view <owner>/<repo> --json viewerDefaultMergeMethod` (derive `<owner>/<repo>` from the PR reference, not from the local checkout) and pass the corresponding flag (`--squash`, `--rebase`, or `--merge`) -- a strategy flag is mandatory because `gh pr merge` errors in non-interactive contexts without one. Run `gh pr merge <pr-ref> --<strategy> --match-head-commit <reviewed-ref>` where `<reviewed-ref>` is the SHA captured at triage time, so the merge is pinned to the exact commit that was reviewed. If `gh pr merge` exits non-zero, surface the error output to the user and stop. On decline, cancel, skip, non-PR target, or any condition not met: stop.
148
148
 
149
149
  **Severity rubric (impact axis only — severity measures blast radius and reachability, never category):**
150
150
  - `critical` — data loss, auth bypass, secret exposure, RCE. If it cannot cause unauthorized access or data loss, it is NOT critical.
@@ -0,0 +1,2 @@
1
+ import { Command } from 'commander';
2
+ export declare function registerCapturesCommand(program: Command): void;