Function
getBackupFileName
(filePath: string, version: number)
Source from the content-addressed store, hash-verified
| 725 | } |
| 726 | |
| 727 | function getBackupFileName(filePath: string, version: number): string { |
| 728 | const fileNameHash = createHash('sha256') |
| 729 | .update(filePath) |
| 730 | .digest('hex') |
| 731 | .slice(0, 16) |
| 732 | return `${fileNameHash}@v${version}` |
| 733 | } |
| 734 | |
| 735 | function resolveBackupPath(backupFileName: string, sessionId?: string): string { |
| 736 | const configDir = getClaudeConfigHomeDir() |
Tested by
no test coverage detected