diff options
author | Eduardo Pedroni <e.pedroni91@gmail.com> | 2018-04-05 22:45:13 +0200 |
---|---|---|
committer | Eduardo Pedroni <e.pedroni91@gmail.com> | 2018-04-05 22:45:13 +0200 |
commit | 4858406212ce03433e68a53d1972264c56802597 (patch) | |
tree | 148849fa72f49e94605abc14dc80a2274cc33fbd /backup | |
parent | ecad592e93045f698786d356ef9f0bbe51a61163 (diff) |
Added error code check to backup script
Diffstat (limited to 'backup')
-rwxr-xr-x | backup | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -40,3 +40,9 @@ fi echo "rsync $RSYNC_OPTS ${1%/}/* $2" >> "$LOG_FILE" rsync $RSYNC_OPTS ${1%/}/* $2 + +if [ $? -eq 0 ]; then + echo "Backup successful." >> "$LOG_FILE" +else + echo "Backup exited with code $?" +fi |