(dir: string, file: MediaFile, index: number)
| 197 | } |
| 198 | |
| 199 | async function writeInput(dir: string, file: MediaFile, index: number): Promise<string> { |
| 200 | const ext = extFromMime(file.mimeType) |
| 201 | const filePath = path.join(dir, `in-${index}.${ext}`) |
| 202 | await fs.writeFile(filePath, file.buffer) |
| 203 | return filePath |
| 204 | } |
| 205 | |
| 206 | function runCommand(command: ffmpeg.FfmpegCommand, outputPath: string): Promise<void> { |
| 207 | return new Promise<void>((resolve, reject) => { |
no test coverage detected