Files
claude-code/mods/diff/hooks/git/parse/hunk-header/hunk-header.ts

6 lines
196 B
TypeScript

/**
* A unified diff's hunk header, `@@ -old[,n] +new[,n] @@`, its two starts
* captured as `old` and `new`.
*/
export const HUNK_HEADER = /^@@ -(?<old>\d+)(?:,\d+)? \+(?<new>\d+)(?:,\d+)? @@/