From 0f7433691efe4b1f90587439fe59428bfa6b82fb Mon Sep 17 00:00:00 2001 From: lassulus Date: Sun, 23 Aug 2015 16:05:09 +0200 Subject: add missing song check --- bin/checkMissing | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 bin/checkMissing (limited to 'bin') diff --git a/bin/checkMissing b/bin/checkMissing new file mode 100755 index 0000000..16cb477 --- /dev/null +++ b/bin/checkMissing @@ -0,0 +1,9 @@ +#!/bin/sh + +uri=$1 +musicDir=${musicDir-./} +id=$(echo "$uri" | sed -n 's@^https\?://www\.youtube\.com/watch?v=@@p' | sed 's/#.*$//') + +if ! file=$(find $musicDir | grep -q "[-]$id\\.ogg\$"); then + echo $uri +fi -- cgit v1.2.3