Skip to content

flicat/fast-bird-download

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nodejs-download

nodejs download module, support multi-threaded segmented download, breakpoint renewal.

Usage

download(urlList, dir[, headers, retryCount])

Example:

   const download = require('./src/download')
    download([
        'http://172.31.1.235:3001/file_1.zip',
        'http://172.31.1.235:3001/file_2.exe',
        'http://172.31.1.235:3001/file_3.exe'
    ], './download').then(successList => {
        console.log('download success: ', successList)
    })

Arguments

urlList[Array]

Array of files to download

dir[String]

Download directory, Default value: './download'

headers[Object]

Header information of network request

retryCount[Number]

Number of retries after download failure

Releases

No releases published

Packages

No packages published