chldydgh4687 / 00Self-Linux_trial_and_error

Linux & DeepLearning
0 stars 0 forks source link

[TIP][Linux] 구글 드라이브 파일 다운로드받기 shell 명령어 #47

Open chldydgh4687 opened 4 years ago

chldydgh4687 commented 4 years ago
* 일반 크기의 파일

wget --no-check-certificate 'https://docs.google.com/uc?export=download&id=FILEID' -O FILENAME

* 큰 크기의 파일 ("파일이 너무 커서 Google에서 바이러스를 검사할 수 없습니다. 그래도 파일을 다운로드하시겠습니까?" 라고 뜨는 파일들)

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