File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -99,17 +99,16 @@ __get_remote_file() {
99
99
return 0
100
100
fi
101
101
102
- failed =false
102
+ local succeeded =false
103
103
if __machine_has wget; then
104
- wget --tries 10 --quiet -O " $local_path " " $remote_path " || failed =true
104
+ wget --tries 10 --quiet -O " $local_path " " $remote_path " && succeeded =true
105
105
fi
106
106
107
- if [ " $failed " = true ] && __machine_has curl; then
108
- failed=false
109
- curl --retry 10 -sSL -f --create-dirs -o " $local_path " " $remote_path " || failed=true
107
+ if [ " $succeeded " = false ] && __machine_has curl; then
108
+ curl --retry 10 -sSL -f --create-dirs -o " $local_path " " $remote_path " && succeeded=true
110
109
fi
111
110
112
- if [ " $failed " = true ]; then
111
+ if [ " $succeeded " = false ]; then
113
112
__error " Download failed: $remote_path " 1>&2
114
113
return 1
115
114
fi
You can’t perform that action at this time.
0 commit comments