Skip to content

Instantly share code, notes, and snippets.

@lexszero
Created February 2, 2017 20:30
Show Gist options
  • Save lexszero/116fc5b6ee41ff9a8fc64cfb50f33673 to your computer and use it in GitHub Desktop.
Save lexszero/116fc5b6ee41ff9a8fc64cfb50f33673 to your computer and use it in GitHub Desktop.
/home/lexs/bin/youtube-dl-check
#!/usr/bin/python
import sys
from youtube_dl.extractor import gen_extractor_classes
url = sys.argv[1]
suitable = [x.IE_NAME for x in gen_extractor_classes() if x.IE_NAME != 'generic' and x.suitable(url)]
if not suitable:
sys.exit(1)
print("\n".join(suitable))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment