( prevContent: string, newContent: string, )
| 706 | } |
| 707 | |
| 708 | async function writeCacheBreakDiff( |
| 709 | prevContent: string, |
| 710 | newContent: string, |
| 711 | ): Promise<string | undefined> { |
| 712 | try { |
| 713 | const diffPath = getCacheBreakDiffPath() |
| 714 | await mkdir(getClaudeTempDir(), { recursive: true }) |
| 715 | const patch = createPatch( |
| 716 | 'prompt-state', |
| 717 | prevContent, |
| 718 | newContent, |
| 719 | 'before', |
| 720 | 'after', |
| 721 | ) |
| 722 | await writeFile(diffPath, patch) |
| 723 | return diffPath |
| 724 | } catch { |
| 725 | return undefined |
| 726 | } |
| 727 | } |
no test coverage detected