File tree 1 file changed +28
-0
lines changed
1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -284,3 +284,31 @@ function build_current_version {
284
284
echo " GUI e2e executable for current version already exists at $gui_test_bin , skipping build"
285
285
fi
286
286
}
287
+
288
+ function download_app_package {
289
+ local version=$1
290
+ local os=$2
291
+ local package_repo=" "
292
+
293
+ if is_dev_version " $version " ; then
294
+ package_repo=" ${BUILD_DEV_REPOSITORY} "
295
+ else
296
+ package_repo=" ${BUILD_RELEASE_REPOSITORY} "
297
+ fi
298
+
299
+ local filename
300
+ filename=$( get_app_filename " $version " " $os " )
301
+ local url=" ${package_repo} /$version /$filename "
302
+
303
+ local package_dir
304
+ package_dir=$( get_package_dir)
305
+ if [[ ! -f " $package_dir /$filename " ]]; then
306
+ echo " Downloading build for $version ($os ) from $url "
307
+ if ! curl -sf -o " $package_dir /$filename " " $url " ; then
308
+ echo " Failed to download package from $url (hint: build may not exist, check the url)" 1>&2
309
+ exit 1
310
+ fi
311
+ else
312
+ echo " App package for version $version ($os ) already exists at $package_dir /$filename , skipping download"
313
+ fi
314
+ }
You can’t perform that action at this time.
0 commit comments