(path: string = installPlanPath())
| 65 | |
| 66 | |
| 67 | export function readInstallPlan(path: string = installPlanPath()): InstallPlan | undefined { |
| 68 | try { |
| 69 | const raw = readFileSync(path, 'utf8'); |
| 70 | const parsed = JSON.parse(raw) as unknown; |
| 71 | if (!isInstallPlan(parsed)) return undefined; |
| 72 | return parsed; |
| 73 | } catch { |
| 74 | return undefined; |
| 75 | } |
| 76 | } |
| 77 | |
| 78 | |
| 79 | export function deleteInstallPlan(path: string = installPlanPath()): void { |
no test coverage detected