summaryrefslogtreecommitdiff
path: root/odin/strm/cache_media
diff options
context:
space:
mode:
Diffstat (limited to 'odin/strm/cache_media')
-rw-r--r--odin/strm/cache_media8
1 files changed, 8 insertions, 0 deletions
diff --git a/odin/strm/cache_media b/odin/strm/cache_media
index 796bccf0..c34e20fe 100644
--- a/odin/strm/cache_media
+++ b/odin/strm/cache_media
@@ -22,6 +22,8 @@ function notmuch {
22 done 22 done
23} 23}
24 24
25acted=false
26
25while { 27while {
26 results=$(notmuch search --sort=oldest-first --output=messages "( tag:inbox AND is:media AND is:unread ) AND NOT ( tag:new OR tag:killed OR tag:failed OR tag:cached )") 28 results=$(notmuch search --sort=oldest-first --output=messages "( tag:inbox AND is:media AND is:unread ) AND NOT ( tag:new OR tag:killed OR tag:failed OR tag:cached )")
27 ids=("${(f)results}") 29 ids=("${(f)results}")
@@ -34,5 +36,11 @@ while {
34 36
35 for id (${ids}); do 37 for id (${ids}); do
36 systemctl --user start $(systemd-escape --template=download-youtube@.service ${id}) 38 systemctl --user start $(systemd-escape --template=download-youtube@.service ${id})
39
40 acted=true
37 done 41 done
38done 42done
43
44if ${acted}; then
45 systemctl --no-block start uucico@hel.service
46fi