From 45505be93f5c266f43d34df0d6d2b1e18ababa2b Mon Sep 17 00:00:00 2001 From: Alexander Barton Date: Fri, 1 Dec 2017 11:44:28 +0100 Subject: [PATCH] Don't set "pipefail", it changes behaviour! Using "pipefail" is a good idea (fail early), but changes behaviour and leeds to undesired side-effects when commands exit because of the PIPEFAIL signal (exit code 141). References: - https://stackoverflow.com/questions/19120263/why-exit-code-141-with-grep-q - http://www.tldp.org/LDP/lpg/node20.html - http://www.pixelbeat.org/programming/sigpipe_handling.html This partially reverts commit 2177f5af642e. --- bin/backup-audit | 1 - bin/backup-script | 1 - bin/backup-status | 1 - 3 files changed, 3 deletions(-) diff --git a/bin/backup-audit b/bin/backup-audit index 0dc2995..651d0e3 100755 --- a/bin/backup-audit +++ b/bin/backup-audit @@ -29,7 +29,6 @@ default_target="/var/backups" # Set shell options. shopt -s nullglob -set -o pipefail # Search configuration file (last one is used as default!) for conf in \ diff --git a/bin/backup-script b/bin/backup-script index 395fe9e..a04433c 100755 --- a/bin/backup-script +++ b/bin/backup-script @@ -55,7 +55,6 @@ default_tags="" # Set shell options. shopt -s nullglob -set -o pipefail Usage() { { diff --git a/bin/backup-status b/bin/backup-status index 8486873..76e7519 100755 --- a/bin/backup-status +++ b/bin/backup-status @@ -31,7 +31,6 @@ default_target="/var/backups" # Set shell options. shopt -s nullglob -set -o pipefail # Search configuration file (last one is used as default!) for conf in \ -- 2.39.2