1
1
#! /bin/bash
2
- VERSION=4.3.1
2
+ VERSION=4.3.2
3
3
printDownloaderHelp (){
4
4
cat << EOF
5
5
@@ -233,11 +233,11 @@ downloader() {
233
233
;;
234
234
esac
235
235
done
236
- if [[ " $OSTYPE " == " msys" * || " $OSTYPE " == " cygwin" * || " $OSTYPE " == " win32" * ]]; then
237
- echo " Detected Windows OS. Skipping wget2..."
238
- WGET2=0
239
- WGET2_INSTALLED=0
240
- fi
236
+ # if [[ "$OSTYPE" == "msys"* || "$OSTYPE" == "cygwin"* || "$OSTYPE" == "win32"* ]]; then
237
+ # echo "Detected Windows OS. Skipping wget2..."
238
+ # WGET2=0
239
+ # WGET2_INSTALLED=0
240
+ # fi
241
241
# [wget2]
242
242
if command -v wget2 > /dev/null 2>&1 ; then
243
243
WGET2_INSTALLED=1
@@ -388,8 +388,8 @@ downloader() {
388
388
else
389
389
if [[ " ${SILENT} " == 1 ]]; then
390
390
if [[ $WGET2 == 1 ]] && [[ $WGET2_INSTALLED == 1 ]]; then
391
- echo
392
- wget2 -N -nv --progress=bar --tries=${RETRY_MAX} --max-redirect=${MAX_REDIRECTS} --retry-connrefused --timeout=1500 --waitretry=${RETRY_DELAY_S} ${EXTRA_ARGS} ${FINAL_EXTRA_ARGS} ${URLS_TO_DOWNLOAD}
391
+ echo " "
392
+ wget2 -N -nv --no-tcp-fastopen -- progress=bar --tries=${RETRY_MAX} --max-redirect=${MAX_REDIRECTS} --retry-connrefused --timeout=1500 --waitretry=${RETRY_DELAY_S} ${EXTRA_ARGS} ${FINAL_EXTRA_ARGS} ${URLS_TO_DOWNLOAD}
393
393
elif [[ $CURL == 1 ]] && [[ $CURL_INSTALLED == 1 ]]; then
394
394
echo
395
395
curl -Z -L --silent --retry ${RETRY_MAX} --retry-delay ${RETRY_DELAY_S} --max-redirs ${MAX_REDIRECTS} --header " Connection: close" --progress-bar ${EXTRA_ARGS} ${FINAL_EXTRA_ARGS} ${URLS_TO_DOWNLOAD}
@@ -403,8 +403,8 @@ downloader() {
403
403
else
404
404
if [[ $WGET2 == 1 ]] && [[ $WGET2_INSTALLED == 1 ]]; then
405
405
echo " [downloader] [wget2] urls:[$URLS_TO_DOWNLOAD ] args:[$EXTRA_ARGS $FINAL_EXTRA_ARGS "
406
- echo
407
- wget2 -N -c --progress=bar --force-progress --tries=${RETRY_MAX} --max-redirect=${MAX_REDIRECTS} --retry-connrefused --waitretry=${RETRY_DELAY_S} --timeout=1500 ${EXTRA_ARGS} ${FINAL_EXTRA_ARGS} ${URLS_TO_DOWNLOAD}
406
+ echo " "
407
+ wget2 -N -c --no-tcp-fastopen -- progress=bar --force-progress --tries=${RETRY_MAX} --max-redirect=${MAX_REDIRECTS} --retry-connrefused --waitretry=${RETRY_DELAY_S} --timeout=1500 ${EXTRA_ARGS} ${FINAL_EXTRA_ARGS} ${URLS_TO_DOWNLOAD}
408
408
elif [[ $CURL == 1 ]] && [[ $CURL_INSTALLED == 1 ]]; then
409
409
echo " [downloader] [cURL] urls:[$URLS_TO_DOWNLOAD ] args:[$EXTRA_ARGS $FINAL_EXTRA_ARGS ${CONNECTION_EXTRA_ARGS[@]} ]"
410
410
echo
0 commit comments