vdirsyncd (476B)
1 #!/bin/sh 2 set -e 3 4 notidie() { 5 notify "$1" "$2" vdirsyncd 6 exit 1 7 } 8 9 os=$(uname -s | tr '[:upper:]' '[:lower:]') 10 case "$os" in 11 darwin*) 12 while pgrep RotMG; do sleep 60; done 13 while pgrep pinentry; do sleep 60; done 14 ;; 15 esac 16 17 vdirsyncer sync || notify 'Error in vdirsyncer' 'Did not sync properly, check /tmp/vdirsyncd.std{out,err}' vdirsyncd 18 vdirsyncer metasync || notify 'Error in vdirsyncer' 'Did not sync properly, check /tmp/vdirsyncd.std{out,err}' vdirsyncd