summaryrefslogtreecommitdiff
path: root/odin/strm/cleanup_youtube
diff options
context:
space:
mode:
Diffstat (limited to 'odin/strm/cleanup_youtube')
-rwxr-xr-xodin/strm/cleanup_youtube4
1 files changed, 2 insertions, 2 deletions
diff --git a/odin/strm/cleanup_youtube b/odin/strm/cleanup_youtube
index 0df15d0b..694487a5 100755
--- a/odin/strm/cleanup_youtube
+++ b/odin/strm/cleanup_youtube
@@ -2,7 +2,7 @@
2 2
3function notmuch { 3function notmuch {
4 while true; do 4 while true; do
5 result=$($_env NOTMUCH_CONFIG=${HOME}/.notmuch-rss-config @notmuch@/bin/notmuch "$@" 2>&1) 5 result=$(env NOTMUCH_CONFIG=${HOME}/.notmuch-rss-config @notmuch@/bin/notmuch "$@" 2>&1)
6 if ! [[ $result =~ "already locked" ]]; then 6 if ! [[ $result =~ "already locked" ]]; then
7 echo -nE $result 7 echo -nE $result
8 return 8 return
@@ -22,7 +22,7 @@ maxsize=$((1024 * 1024 * 1024 * 50))
22 22
23while [[ $(du -bs $dir | awk '{ print $1; }') -gt $maxsize ]]; do 23while [[ $(du -bs $dir | awk '{ print $1; }') -gt $maxsize ]]; do
24 find $dir -type f -not -path $dir/CACHEDIR.TAG -print0 | \ 24 find $dir -type f -not -path $dir/CACHEDIR.TAG -print0 | \
25 xargs -0 -- $_stat --printf '%W %Y %Z %X %n\0' | \ 25 xargs -0 -- stat --printf '%W %Y %Z %X %n\0' | \
26 sort -t '\0' -z | \ 26 sort -t '\0' -z | \
27 awk -F '\0' '{ gsub("^\\S+\\s+\\S+\\s+\\S+\\s+\\S+\\s+", "", $1); printf "%s\0", $1; }' | \ 27 awk -F '\0' '{ gsub("^\\S+\\s+\\S+\\s+\\S+\\s+\\S+\\s+", "", $1); printf "%s\0", $1; }' | \
28 xargs -0 -- rm -v 28 xargs -0 -- rm -v