From b5abb4e6b41d4628056ee7e0698093847d883f28 Mon Sep 17 00:00:00 2001 From: Ste Vaidis Date: Sat, 24 Dec 2022 23:18:43 +0200 Subject: [PATCH] beter reeport --- backup.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backup.sh b/backup.sh index c157a0d..376961f 100755 --- a/backup.sh +++ b/backup.sh @@ -184,7 +184,8 @@ function umount() { function send_mail() { COPIED=$( cat ${LOG} | grep "Number of created files:" | awk {'print $5'} ) DELETED=$( cat ${LOG} | grep "Number of deleted files:" | awk {'print $5'} ) - SUBJECT="${COPIED} files copied, ${DELETED} files deleted" + TRANSFERRED=$( cat ${LOG} | grep "Number of regular files transferred:" | awk {'print $6'} ) + SUBJECT="${COPIED} files copied, ${DELETED} files deleted, ${TRANSFERRED} files transferred" echo "Backup Report" | mutt -s $SUBJECT -F /etc/muttrc $MAIL_RECIPIENT -a $LOG }