diff --git a/.config/fish/functions/podsync.fish b/.config/fish/functions/podsync.fish deleted file mode 100644 index ff6b1b2..0000000 --- a/.config/fish/functions/podsync.fish +++ /dev/null @@ -1,5 +0,0 @@ -function podsync - cd $D/Videos/YouTube/ - ./clean - tmux new -s 1 -d "command podsync -c $D/Videos/YouTube/config.toml" -end diff --git a/.local/bin/podsync b/.local/bin/podsync new file mode 100755 index 0000000..85ac28c --- /dev/null +++ b/.local/bin/podsync @@ -0,0 +1,8 @@ +#!/bin/bash +cd $D/Videos/YouTube/ + +for f in */*.mp4; do + grep -q "$f" *.xml || rm "$f" +done + +tmux new -s 1 -d "podsync-bin -c $D/Videos/YouTube/config.toml"