execToFileWithTimeout

fun execToFileWithTimeout(command: List<String>, workingDir: File? = null, outputFile: File, timeoutSeconds: Long, onOutputLine: (String) -> Unit? = null, onProcessStarted: (ProcessHandle) -> Unit? = null): Int