summaryrefslogtreecommitdiff
path: root/.local/bin/pod-dl
diff options
context:
space:
mode:
authorBenjamin Chausse <benjamin@chausse.xyz>2020-10-03 19:27:15 -0400
committerBenjamin Chausse <benjamin@chausse.xyz>2020-10-03 19:27:15 -0400
commite371d9edd474bcf89cf5d462eaccb8638900b390 (patch)
treeed07118f5c514a55f23a779a1507640e46fd9ed2 /.local/bin/pod-dl
Initial commit
Diffstat (limited to '.local/bin/pod-dl')
-rwxr-xr-x.local/bin/pod-dl30
1 files changed, 30 insertions, 0 deletions
diff --git a/.local/bin/pod-dl b/.local/bin/pod-dl
new file mode 100755
index 0000000..07e1d6b
--- /dev/null
+++ b/.local/bin/pod-dl
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+tmux kill-session -t Podcast 2 > /dev/null
+
+file=$(tail -n 1 $HOME/.local/share/newsboat/queue)
+url=$(echo $file | sed 's/."\/home.*$//')
+dir=$(echo $file | sed 's/^.*"\/home/\/home/; s/.$//')
+
+$TERMINAL -c dropdown -t Podcast -e $SCRIPTS/utilities/tmux-vlc "$url"
+
+# notify-send -i "$HOME/.fonts/svg/rss.svg" "Download initiated"
+# wget -LO $dir $url && \
+# notify-send -i "$HOME/.fonts/svg/rss.svg" "Download Complete" && \
+# st -e $HOME/.scripts/tools/tm-vlc $dir
+
+
+#!/bin/sh
+
+# tmux kill-session -t tm-vlc
+# killall -q vlc
+
+# file=$(cat $HOME/.local/share/newsboat/queue | sed 2q | tail -n 1)
+# url=$(echo $file | sed 's/."\/home.*$//')
+# dir=$(echo $file | sed 's/^.*"\/home/\/home/; s/.$//')
+
+# notify-send -i "$HOME/.fonts/svg/rss.svg" "Download initiated"
+# setsid wget -LO $dir $url & sleep 2s && st -e $HOME/.scripts/tools/tm-vlc "$dir" && \
+# notify-send -i "$HOME/.fonts/svg/rss.svg" "Download Complete"
+
+# echo "" > $HOME/.local/share/newsboat/queue