Created
April 12, 2024 08:35
-
-
Save luckasRanarison/3d03c7881c7429037b74a89bf77499f1 to your computer and use it in GitHub Desktop.
Upload file to gdrive
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from google.colab import drive | |
drive.mount('/content/gdrive') | |
import requests | |
file_url ="https://download.fedoraproject.org/pub/fedora/linux/releases/39/Workstation/x86_64/iso/Fedora-Workstation-Live-x86_64-39-1.5.iso" | |
r = requests.get(file_url, stream = True) | |
with open("/content/gdrive/My Drive/fedora.iso", "wb") as file: | |
for block in r.iter_content(chunk_size = 1024): | |
if block: | |
file.write(block) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment