#!/bin/bash
exim -bpc
result=$?
if [ $result -gt 50 ]; then
echo "Before sending:" >f.txt
echo $result >>f.txt
exim -qff
exiqgrep -o 86400 -i | xargs exim -Mrm
echo "After force sending:" >>f.txt
exim -bpc >>f.txt
mail -s "Forced sending" zxczxczxc@gmail.com <./f.txt
fi