From f8c6f33188e8c757c76c0e45bfb569e19033f6f4 Mon Sep 17 00:00:00 2001 From: steveokard Date: Fri, 23 Dec 2022 22:06:41 -0500 Subject: [PATCH] new scripts --- scripts/server_bin/gif_purge.sh | 11 +++++++++++ twitch_kody.sh | 3 +++ 2 files changed, 14 insertions(+) create mode 100755 scripts/server_bin/gif_purge.sh create mode 100644 twitch_kody.sh diff --git a/scripts/server_bin/gif_purge.sh b/scripts/server_bin/gif_purge.sh new file mode 100755 index 0000000..fc90954 --- /dev/null +++ b/scripts/server_bin/gif_purge.sh @@ -0,0 +1,11 @@ +#!/bin/bash +#Deletes all MP4's that are less than 4500ms long +#this could be refactored to take advantage of fd's parallel execution with -x + #but should be limited with -j for number of threads +fdfind -e mp4 | while read i; do + length=$(mediainfo --Inform="Video;%Duration%" "$i") + if [[ $length -le 4500 ]]; then + rm "$i" + #kioclient move $i "trash:/" + fi +done \ No newline at end of file diff --git a/twitch_kody.sh b/twitch_kody.sh new file mode 100644 index 0000000..eb42c7b --- /dev/null +++ b/twitch_kody.sh @@ -0,0 +1,3 @@ +#!/bin/bash +cd /home/stev/Videos/Twitch/Kodykins +yt-dlp -f 720p60 https://www.twitch.tv/curlykody/videos