queueue-download
File download queue with unique file names support
Instalation
npm i queueue-download
Usage
const download = ; const files = remote: 'url://to/remote/file' local: '/localpath/to/file' remote: 'url://to/remote/file' local: '/localpath/to/file' ; const res = await ;
Options
async download(files, opts);
Returns an array with results. It never throws an error, all errors are in the result array.
- force — force path creation
- concurrency — number of simultaneous downloads, 'auto' or undefined are equals to cpus number
Id
Also you can add an id
field to the files, and it will be returned in the result.
Unique file names
You can use pattern in the local file name as described in the fsu module
License: MIT