From 5150fc6752136977b9d80f28c0b80ee39aa44ea2 Mon Sep 17 00:00:00 2001 From: Pragmatic Software Date: Sat, 25 Jan 2020 15:32:25 -0800 Subject: [PATCH] modules/date.sh: print errors to stdout --- modules/date.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/date.sh b/modules/date.sh index 4b41f986..31f3782d 100755 --- a/modules/date.sh +++ b/modules/date.sh @@ -1,8 +1,8 @@ #!/bin/bash export TZ=UTC -if (( $# )) && ! read -r TZ < <(IFS=_; find -L /usr/share/zoneinfo/posix -type f -iname "*$**" -printf '%P\n' -quit); then - echo "No match for '$*'." >&2 +if (( $# )) && ! read -r TZ < <(IFS=_; find -L /usr/share/zoneinfo/posix -type f -not -iname 'West' -iname "*$**" -printf '%P\n' -quit); then + echo "No match for '$*'." exit 1 fi if [[ $TZ != UTC ]]; then