Skip to content

Commit

Permalink
add manual param set for google download confirm no virus scan.
Browse files Browse the repository at this point in the history
  • Loading branch information
wildone committed May 20, 2022
1 parent 9e541a7 commit d29f20d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion scripts/download/download-gdrive.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@ function doDownloadGDrive() {
fi

curl -c ./tmp/cookie -s -L "https://drive.google.com/uc?export=download&id=${FILEID}" > /dev/null
curl -Lb ./tmp/cookie "https://drive.google.com/uc?export=download&confirm=`awk '/download/ {print $NF}' ./tmp/cookie`&id=${FILEID}" -o ${FILENAME}
COOKIE_CONFIRM=$(awk '/download/ {print $NF}' ./tmp/cookie)

if [[ "" == "${COOKIE_CONFIRM}" ]]; then
COOKIE_CONFIRM="t"
fi

curl -Lb ./tmp/cookie "https://drive.google.com/uc?export=download&confirm=${COOKIE_CONFIRM}&id=${FILEID}" -o ${FILENAME}

}

Expand Down

0 comments on commit d29f20d

Please sign in to comment.