From 84ad23ae0edb52bd785a38ef87398133e73c41e2 Mon Sep 17 00:00:00 2001 From: "martin f. krafft" Date: Fri, 13 Aug 2010 15:10:58 +0200 Subject: [PATCH 1/1] shut up offlineimap during normal cron runs --- .bin/offlineimap | 2 ++ .crontab.d/offlineimap | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.bin/offlineimap b/.bin/offlineimap index 5bf7e52..f55fee5 100755 --- a/.bin/offlineimap +++ b/.bin/offlineimap @@ -1,6 +1,8 @@ #!/bin/sh set -eu +[ "${1:-}" = -q ] && exec >/dev/null + VAR=$HOME/.var/offlineimap LOCKFILE="$VAR/.cron.lock" trap "rm -f $LOCKFILE" 0 1 2 3 4 5 6 7 8 10 11 12 13 14 15 diff --git a/.crontab.d/offlineimap b/.crontab.d/offlineimap index 6c49698..d2e4061 100644 --- a/.crontab.d/offlineimap +++ b/.crontab.d/offlineimap @@ -1,3 +1,3 @@ -*/30 * * * * sleep $((900 * $RANDOM / 32768)) && ip r | grep -q via && $HOME/.bin/offlineimap -38 */4 * * * sleep $((60 * $RANDOM / 32768)) && ip r | grep -q via && $HOME/.bin/offlineimap -a logcheck -55 */8 * * * sleep $((300 * $RANDOM / 32768)) && ip r | grep -q via && $HOME/.bin/offlineimap -a madduck.net-bulk +*/30 * * * * sleep $((900 * $RANDOM / 32768)) && ip r | grep -q via && $HOME/.bin/offlineimap -q +38 */4 * * * sleep $((60 * $RANDOM / 32768)) && ip r | grep -q via && $HOME/.bin/offlineimap -q -a logcheck +55 */8 * * * sleep $((300 * $RANDOM / 32768)) && ip r | grep -q via && $HOME/.bin/offlineimap -q -a madduck.net-bulk -- 2.39.5