fydy / elaw

:100: 个人博客站,记录一些事。
https://git.io/JWxoK
25 stars 8 forks source link

linux服务器下载google drive大文件 #46

Open fydy opened 4 years ago

fydy commented 4 years ago

 - 如果没有权限,使用下面的命令

chmod +x ./ss.sh

持续更新

ghost commented 2 years ago

Hello, is this tool still work?

fydy commented 2 years ago

Hello, is this tool still work?

Yes it is. I just tested it. Are you having any problems?

huangsiyong commented 2 years ago

It doesn't work when I want to download a new one:

filename="robeata_dc.zip"
file_id="1VfBbhAgFFXMn0lE5YFYtI3OiJpDXN9aT"
query=`curl  -c ./cookie.txt -s -L "https://drive.google.com/uc?export=download&id=${file_id}" \
| perl -nE'say/uc-download-link.*? href="(.*?)\">/' \
| sed -e 's/amp;//g' | sed -n 2p`
url="https://drive.google.com$query"
curl -b ./cookie.txt -L -o ${filename} $url 
huangsiyong commented 2 years ago

Hi, I have tested serveral times but I still fail to download the large file whose file_id is 1VyHAjYsOb3Ae_Kg-h5bdVefBHaVoRG86. Actually, I can download the file in your original shell but I only get a HTML file if I change the file_id. What's the reason?