framework
Version:
The (AI) Framework: turnkey, zero-config AI orchestration that wraps a coding-agent CLI (Claude Code) as a black box and takes you from an idea to a running app. Vite for AI.
28 lines • 1.74 kB
TypeScript
/**
* GitHub's issue-closing grammar, and how to defuse it (#1567).
*
* A pull request whose body says `close #1164` closes that issue the moment the PR merges.
* That is the wanted behaviour when the PR completes the issue — the handoff puts `(fix #42)`
* on the title of an implementing agent's PR for exactly that reason (#1334). It is the wrong
* behaviour when the PR delivers something short of the work: a plan agent's PR lands a plan
* whose own text says the implementation is still to come, and a sentence like "…then close
* #1164" reads perfectly sensibly to the human reviewing it while quietly closing the ticket.
*
* That happened (#1560 closed #1164, and the next tickets sync then deleted the ticket and its
* fresh plan). The cure is not to forbid the phrase — the agent is describing its plan, and the
* sentence is true — but to break the adjacency GitHub's parser needs. The keyword only counts
* when the reference follows it directly, so two words in between end its authority while the
* sentence keeps saying what it said.
*/
/**
* Rewrite every closing phrase in `text` so GitHub stops reading it as a command, leaving the
* issue reference itself untouched: `close #1164` becomes `close the ticket #1164`.
*
* The reference stays live — clickable, and still cross-referenced onto the issue's own timeline,
* so the ticket is told a pull request mentioned it. Only the closing authority is removed.
*
* Idempotent by construction: after the rewrite the keyword is followed by the filler rather than
* by a reference, so a second pass finds nothing to change.
*/
export declare function defuseClosingKeywords(text: string): string;
//# sourceMappingURL=closing-keywords.d.ts.map