summaryrefslogtreecommitdiff
path: root/bin/extra/ehbtodl
diff options
context:
space:
mode:
authorRaymaekers Luca <raymaekers.luca@gmail.com>2023-02-15 16:31:56 +0100
committerRaymaekers Luca <raymaekers.luca@gmail.com>2023-02-15 16:47:43 +0100
commit3b2a78935fd6550521f719a10e5b0fceb1ddb350 (patch)
tree7c50801d6bb5b7abba3df6352ed43df454a4dbcb /bin/extra/ehbtodl
Not really but, First commit!
Diffstat (limited to 'bin/extra/ehbtodl')
-rwxr-xr-xbin/extra/ehbtodl9
1 files changed, 9 insertions, 0 deletions
diff --git a/bin/extra/ehbtodl b/bin/extra/ehbtodl
new file mode 100755
index 0000000..39d8621
--- /dev/null
+++ b/bin/extra/ehbtodl
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+echo "$1" | sed 's/-H/\\\n\t&/g' | sed '/gzip/d' > /tmp/curlcommand.sh
+sh /tmp/curlcommand.sh > /tmp/ehbso.html
+vids="$(grep -oE "youtube\.com/embed/.{11}" /tmp/ehbso.html | cut -d'/' -f 3 | tr '\n' ' ')"
+for i in $vids
+do
+ echo "https://www.youtube.com/watch?v=$i"
+done > /tmp/todownload
+# yt-dlp -P "$HOME/Downloads/vids" -o "%(title)s" -a /tmp/todownload