#!/bin/bash #Input list of asset chains source ~/scripts/coinlist # Minimum number of UTXOs to maintain MINUTXOS=100 # Amount of UTXOs to create at one time SPLITAMNT=75 #Print Date and Time now=$(date +"%Y-%m-%d %T%z") printf "$now \n"; # Manual Check of BTC, CHIPS, KMD echo "Checking BTC, CHIPS, KMD" cd ~ echo -n BTC UTXOS="$(bitcoin-cli listunspent | grep .0001 | wc -l)" echo -n -e '\t\t';echo -n "$UTXOS" if [ "$UTXOS" -lt "$MINUTXOS" ] then echo -n " - SPLITFUNDING BTC" RESULT="$(acsplit BTC $SPLITAMNT)" echo $RESULT fi echo "" echo -n CHIPS UTXOS="$(chips-cli listunspent | grep .0001 | wc -l)" echo -n -e '\t\t';echo -n "$UTXOS" if [ "$UTXOS" -lt "$MINUTXOS" ] then echo -n "SPLITFUNDING CHIPS" RESULT="$(acsplit CHIPS $SPLITAMNT)" echo $RESULT fi echo "" echo -n KMD UTXOS="$(komodo-cli listunspent | grep .0001 | wc -l)" echo -n -e '\t\t';echo -n "$UTXOS" if [ "$UTXOS" -lt "$MINUTXOS" ] then echo -n " - SPLITFUNDING KMD" RESULT="$(acsplit KMD 100)" echo $RESULT fi echo "" echo "Checking Other Coins" # Check the rest of the coins using a loop count=0 while [ "x${coinlist[count]}" != "x" ] do all=${coinlist[count]} name=${all%% *} if [ "$name" != "" ] then echo -n "$name" UTXOS="$(komodo-cli -ac_name=$name listunspent | grep .0001 | wc -l)" echo -n -e '\t\t';echo -n "$UTXOS" if [ "$UTXOS" -lt "$MINUTXOS" ] then echo -n " - SPLIT FUNDING: $name" RESULT="$(acsplit $name $SPLITAMNT)" echo $RESULT fi fi count=$(( $count +1 )) echo "" done echo "FINISHED"