Browse Source

Switch to using POD_SUB_DIR

Samuel W. Flint 1 year ago
parent
commit
58c55e40e8
1 changed files with 3 additions and 3 deletions
  1. 3 3
      pod

+ 3 - 3
pod

@@ -35,7 +35,7 @@ git_annex_wrap() {
 }
 
 find_unlistened() {
-    git_annex_wrap find --metadata "tag=unlistened" --include='Podcasts/*' $@
+    git_annex_wrap find --metadata "tag=unlistened" --include="${POD_SUB_DIR}/*" $@
 }
 
 play_pod() {
@@ -65,7 +65,7 @@ get_cur_file() {
 set_loc() {
     FILE=$1
     SEEK=$2
-    if echo $FILE | grep 'Podcasts/' > /dev/null ; then
+    if echo $FILE | grep "${POD_SUB_DIR}/" > /dev/null ; then
         git_annex_wrap metadata -s "seek_time=${SEEK}" "${FILE}"
     fi
 }
@@ -157,7 +157,7 @@ case "$CMD" in
             done
         git annex add ${POD_SUB_DIR}
         git commit -m "Caught podcasts"
-        git annex find --include='Podcasts/*' --and --not --metadata tag=listened |\
+        git annex find --include="${POD_SUB_DIR}/*" --and --not --metadata tag=listened |\
             xargs git annex metadata --tag unlistened
         mpc update
         cd $CUR_DIR