(sessionId: string)
| 427 | } |
| 428 | |
| 429 | export function sessionIdExists(sessionId: string): boolean { |
| 430 | const projectDir = getProjectDir(getOriginalCwd()) |
| 431 | const sessionFile = join(projectDir, `${sessionId}.jsonl`) |
| 432 | const fs = getFsImplementation() |
| 433 | try { |
| 434 | fs.statSync(sessionFile) |
| 435 | return true |
| 436 | } catch { |
| 437 | return false |
| 438 | } |
| 439 | } |
| 440 | |
| 441 | // exported for testing |
| 442 | export function getNodeEnv(): string { |
no test coverage detected