()
| 31 | } |
| 32 | |
| 33 | function getTranscriptPath(): string { |
| 34 | const sessionId = getSessionId() |
| 35 | const projectDir = getSessionProjectDir() |
| 36 | if (projectDir) return join(projectDir, `${sessionId}.jsonl`) |
| 37 | return join( |
| 38 | getClaudeConfigHomeDir(), |
| 39 | 'projects', |
| 40 | sanitizePath(getOriginalCwd()), |
| 41 | `${sessionId}.jsonl`, |
| 42 | ) |
| 43 | } |
| 44 | |
| 45 | function truncate(s: string, maxLen: number): string { |
| 46 | return s.length > maxLen ? `${s.slice(0, maxLen)}…` : s |
no test coverage detected