universal twitch archiving script

This commit is contained in:
Stefen Auris 2023-02-04 00:48:28 -05:00
parent d81ad7b2d4
commit 998e76a8e1
3 changed files with 25 additions and 6 deletions

View file

@ -0,0 +1,25 @@
#!/bin/bash
if [[ -z "$2" ]]; then
echo "please provide both parameters"
exit 1
fi
while getopts u:f: flag
do
case "${flag}" in
u) username=${OPTARG};;
f) format=${OPTARG};;
h) help(); exit;;
esac
done
cd /home/stev/Videos/Twitch/$username
yt-dlp -q -f $format "https://www.twitch.tv/$username/videos?filter=archives&sort=time"
help()
{
echo "Download all the past broadcasts from a twitch user"
echo "Requires 2 Parameters:"
echo " -u the username of the twitch user"
echo " -f the encoding format for the videos, which are fed to yt-dlp"
}

View file

@ -1,3 +0,0 @@
#!/bin/bash
cd /home/stev/Videos/Twitch/Kodykins
yt-dlp -q -f 720p60 https://www.twitch.tv/curlykody/videos

View file

@ -1,3 +0,0 @@
#!/bin/bash
cd /home/stev/Videos/Twitch/spaceyeen
yt-dlp -q -f 720p60 https://www.twitch.tv/spaceyeen/videos