From f0b6cae2ea7cc69e1004312f0055d8a87963db5c Mon Sep 17 00:00:00 2001 From: cimryan Date: Sat, 3 Nov 2018 10:44:29 -0700 Subject: [PATCH] Pass --fail to curl Ensure that the setup process will stop early if a script can't be retreived. --- setup/pi/setup-teslausb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup/pi/setup-teslausb b/setup/pi/setup-teslausb index 611fb0b..c478e5b 100644 --- a/setup/pi/setup-teslausb +++ b/setup/pi/setup-teslausb @@ -113,7 +113,7 @@ function get_script () { local name="$2" local remote_path="${3:-}" - curl -o "$local_path/$name" https://raw.githubusercontent.com/"$REPO"/teslausb/"$BRANCH"/"$remote_path"/"$name" + curl --fail -o "$local_path/$name" https://raw.githubusercontent.com/"$REPO"/teslausb/"$BRANCH"/"$remote_path"/"$name" # wget -O "$local_path/$name" https://raw.githubusercontent.com/"$REPO"/teslausb/"$BRANCH"/"$remote_path"/"$name" chmod +x "$local_path/$name" setup_progress "Downloaded $local_path/$name ..."