Skip to content

Instantly share code, notes, and snippets.

@rjchee
Created February 22, 2019 02:35
Show Gist options
  • Save rjchee/297fba7fd697ae6424e6028a1ecc09f6 to your computer and use it in GitHub Desktop.
Save rjchee/297fba7fd697ae6424e6028a1ecc09f6 to your computer and use it in GitHub Desktop.
Download videos
import os
import subprocess
import sys
import xml.etree.ElementTree as ET
with open(sys.argv[1], 'r') as rss:
et = ET.parse(rss)
root = et.getroot()
for name, url in zip((e.text for e in root.findall('./channel/item/title')), (e.attrib['url'] for e in root.findall('./channel/item/enclosure'))):
download_name = f"{name.replace(' ', '-')}.mp4"
if os.path.isfile(download_name):
print(f'Skipping {download_name} because it already exists')
else:
subprocess.run(['wget', f"-O{download_name}", url])
@leahzj
Copy link

leahzj commented Aug 4, 2023

StreamFab is a software which can download videos from 1000+sites, such us youtube, facebook, twitter,vime,etc.For example, method to download videos from tver please check out: tver ダウンロード pc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment