(inputFilePath: string, outputFilePath: string)
| 3 | import path from 'node:path'; |
| 4 | import { promisify } from 'node:util'; |
| 5 | |
| 6 | const execFileAsync = promisify(execFile); |
| 7 | |
| 8 | export async function decompressTo(inputFilePath: string, outputFilePath: string): Promise<void> { |
| 9 | const archive = path.resolve(inputFilePath); |
| 10 | const destination = path.resolve(outputFilePath); |
| 11 | |
| 12 | try { |
| 13 | // `extract-zip` stalls or exits early with Node 26, which is the pinned |
| 14 | // runtime used by mise. `unzip` works on the supported macOS/Linux hosts. |
| 15 | // Avoid restoring stale reproducible-archive timestamps so temporary |
| 16 | // directory cleaners do not delete assets from a live web session. |
| 17 | await execFileAsync('unzip', ['-DD', '-q', '-o', archive, '-d', destination]); |
no test coverage detected