platform/pods/workspace/download-init-scripts.sh
Andrey Sobolev 2b03c56939
UBERF-9633: More proper fix (#8249)
Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
2025-03-17 16:37:13 +04:00

15 lines
489 B
Bash
Executable File

#!/usr/bin/env bash
export INIT_SCRIPTS_BRANCH=${INIT_SCRIPTS_BRANCH:-unified-init-scripts}
# Download init repository
# Check if the file already exists
if [ -e "${INIT_SCRIPTS_BRANCH}.zip" ]; then
echo "File ${INIT_SCRIPTS_BRANCH}.zip already exists, skipping download"
else
wget https://github.com/hcengineering/init/archive/refs/heads/${INIT_SCRIPTS_BRANCH}.zip
fi
unzip ${INIT_SCRIPTS_BRANCH}.zip -d ./temp
rm -rf ./init
mv temp/init-${INIT_SCRIPTS_BRANCH} ./init
rm -rf ./temp