From 0044281b9da92b6b4a01730b5dcd5535a0a3dc6c Mon Sep 17 00:00:00 2001 From: JustAnotherArchivist Date: Thu, 30 Sep 2021 02:23:26 +0000 Subject: [PATCH] Add YouTube channel listing script --- youtube-channel-list.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 youtube-channel-list.py diff --git a/youtube-channel-list.py b/youtube-channel-list.py new file mode 100644 index 0000000..8761d9f --- /dev/null +++ b/youtube-channel-list.py @@ -0,0 +1,9 @@ +import sys +import yt_dlp + + +with yt_dlp.YoutubeDL({'quiet': True}) as ydl: + ie = ydl.get_info_extractor('YoutubeTab') + for url in sys.argv[1:]: + for entry in ie.extract(url)['entries']: + print(entry['id'])