diff --git a/src/index.ts b/src/index.ts index d656057..9142036 100644 --- a/src/index.ts +++ b/src/index.ts @@ -41,8 +41,13 @@ const main = async () => //Log info(`Downloaded ${transferred}K out of ${total}K (${percent}%)`); }; + const url = isWindows ? 'https://win.wasmer.io' : 'https://get.wasmer.io'; await pipeline( - got.stream(isWindows ? 'https://win.wasmer.io' : 'https://get.wasmer.io').on('downloadProgress', progressHandler), + got.stream(url, { + retry: { + limit: 10, + } + }).on('downloadProgress', progressHandler), createWriteStream(tmp, { mode: 0o655 }) @@ -92,4 +97,4 @@ const main = async () => main().catch(error => { throw error; -}); \ No newline at end of file +});