cake_wallet/model_generator.sh

32 lines
No EOL
778 B
Bash
Executable file

CURRENCIES=(
"core"
"evm"
"monero"
"bitcoin"
"haven"
"nano"
"bitcoin_cash"
"lightning"
"solana"
"ethereum"
"polygon"
)
CURRENCY=$1
if [ "$CURRENCY" == "all" ]; then
for dir in "${CURRENCIES[@]}"; do
echo "Processing cw_$dir"
cd "cw_$dir" && flutter pub get && flutter packages pub run build_runner build --delete-conflicting-outputs && cd ..
done
else
if [[ " ${CURRENCIES[@]} " =~ " $CURRENCY " ]]; then
echo "Processing cw_$CURRENCY"
cd "cw_$CURRENCY" && flutter pub get && flutter packages pub run build_runner build --delete-conflicting-outputs && cd ..
else
echo "Invalid currency type. Available options: all, ${CURRENCIES[@]}"
exit 1
fi
fi
flutter packages pub run build_runner build --delete-conflicting-outputs