X-Git-Url: https://git.madduck.net/etc/offlineimap.git/blobdiff_plain/92fd48ede228e9fdd93d57622bf86a584c66c25c..2cb89d7d88d76359b7d37780e02dc1750fff1fe4:/.bin/offlineimap diff --git a/.bin/offlineimap b/.bin/offlineimap index 5bf7e52..82428cd 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 @@ -10,14 +12,10 @@ if ! lockfile -0 -r0 -l 3600 "$LOCKFILE" 2>/dev/null; then fi if ! test -t 0; then - echo Renicing because we are not run interactively… >&2 + echo Renicing because we are not run interactively… renice 20 -p $$ >/dev/null ionice -c3 -p $$ fi ret=0 -/usr/bin/offlineimap -o "$@" || exit $? - -if [ -x "$(command -v notmuch)" ]; then - notmuch new || exit $? -fi +/usr/bin/offlineimap "$@" || exit $?