Skip to content

Commit 50622b7

Browse files
authored
GEOMESA-3561 Fix install-dependencies.sh to exit with non-zero status if a download fails (#3516)
1 parent c06600a commit 50622b7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

geomesa-tools/conf-filtered/functions.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ function download_urls() {
182182
fname="$(basename "$url")" # filename we'll save to
183183
tmpfile=$(mktemp)
184184
# -sS disables progress meter but keeps error messages, -f don't save failed files, -o write to destination file, -L follow redirects
185-
downloads+=("(echo >&2 fetching $fname && curl -LsSfo '$tmpfile' '$url' && mv '$tmpfile' '${dest}/${fname}' && chmod 644 '${dest}/${fname}') || echo [ERROR] Failed to fetch $fname")
185+
downloads+=("(echo >&2 fetching $fname && curl -LsSfo '$tmpfile' '$url' && mv '$tmpfile' '${dest}/${fname}' && chmod 644 '${dest}/${fname}') || (export error=\$?; echo [ERROR] Failed to fetch $fname; exit \$error)")
186186
done
187187
# pass to xargs to run with 4 threads
188188
# delimit with null char to avoid issues with spaces

0 commit comments

Comments
 (0)