budibase/scripts/pro/install.sh

23 lines
512 B
Bash
Raw Normal View History

2022-04-21 22:55:16 +02:00
if [[ -z "${CI}" ]]; then
echo 'Cannot run insall.sh unless in CI'
exit 0
fi
BRANCH=$1
BASE_BRANCH=$2
2022-04-21 22:55:16 +02:00
cd ../
echo "Cloning pro repo..."
2022-04-21 23:18:19 +02:00
git clone https://$PERSONAL_ACCESS_TOKEN@github.com/Budibase/budibase-pro.git
2022-04-21 22:55:16 +02:00
cd budibase-pro
# Try to checkout the matching pro branch
git checkout $BRANCH
# Try to checkout the matching pro base (master or develop) branch
git checkout $BASE_BRANCH
# If neither branch exists continue with default branch 'develop'
2022-04-21 22:55:16 +02:00
git pull
echo "Initializing pro repo..."
yarn setup