From 2ca7b6b8069a6dfb66b0cb8cd6512cb5832f4d71 Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Mon, 8 Feb 2016 23:33:40 +0000 Subject: [PATCH] Fix sh script for non-bash shells --- build-data/build-data-import.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build-data/build-data-import.sh b/build-data/build-data-import.sh index 219549c2..4f45be81 100755 --- a/build-data/build-data-import.sh +++ b/build-data/build-data-import.sh @@ -9,10 +9,10 @@ fetch() echo "Fetch $FILE" if [ ! -f "$FILE" ] || test "`find $FILE -mtime $TIME`"; then curl -L -o "$FILE" -z "$FILE" "$LINK" - if [[ "$FILE" =~ \.gz$ ]]; then + if [[ "$FILE" == *.gz ]]; then gunzip -k -f "$FILE" fi - if [[ "$FILE" =~ \.zip$ ]]; then + if [[ "$FILE" == *.zip ]]; then unzip -o "$FILE" fi fi