()
| 314 | } |
| 315 | |
| 316 | export const load = () => { |
| 317 | logger.info("[Binaries] Initializing managed binary registry") |
| 318 | |
| 319 | // Enhance PATH with any previously downloaded binaries |
| 320 | enhancePath() |
| 321 | |
| 322 | // Eagerly download any binaries that aren't available yet — deferred until app is ready |
| 323 | // because net.fetch requires the app to be fully initialized |
| 324 | app.whenReady().then(() => { |
| 325 | for (const name of Object.keys(REGISTRY)) { |
| 326 | if (!resolve(name)) { |
| 327 | ensureRuntimeBinary(name).catch((err) => { |
| 328 | logger.warn(`[Binaries] Background download of ${name} failed:`, err instanceof Error ? err.message : err) |
| 329 | }) |
| 330 | } |
| 331 | } |
| 332 | }) |
| 333 | } |
| 334 | |
| 335 | export const cleanup = () => { |
| 336 | logger.info("[Binaries] Cleanup called") |
nothing calls this directly
no test coverage detected