From 67cd569684036070b93daf48aae1baa452af06f9 Mon Sep 17 00:00:00 2001 From: poka Date: Tue, 30 Mar 2021 20:04:51 +0200 Subject: [PATCH] Remove debug; fix --- scripts/geoloc-members-json.sh | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/scripts/geoloc-members-json.sh b/scripts/geoloc-members-json.sh index 9873710..82966dc 100755 --- a/scripts/geoloc-members-json.sh +++ b/scripts/geoloc-members-json.sh @@ -24,9 +24,6 @@ fi echo "[" > $FILE -ii=0 -jj=0 - for i in $DATA_MBR; do result=$(jaklis get -p $i) geoPoint=$(echo "$result" | jq .geoPoint 2>/dev/null) @@ -37,8 +34,6 @@ for i in $DATA_MBR; do isMbr='"isMember": true,' resultWithMbr=$(echo "$result" | sed "s/\"geoPoint\": {/$isMbr \"geoPoint\": {/g") echo "$resultWithMbr," >> $FILE - ((ii++)) - [[ $ii > 10 ]] && break; fi done @@ -52,8 +47,6 @@ for i in $DATA_LARF; do isMbr='"isMember": false,' resultWithMbr=$(echo "$result" | sed "s/\"geoPoint\": {/$isMbr \"geoPoint\": {/g") echo "$resultWithMbr," >> $FILE - ((jj++)) - [[ $jj > 10 ]] && break; fi done @@ -61,5 +54,4 @@ sed -i '$ d' $FILE echo "}" >> $FILE echo "]" >> $FILE -[[ -f $FINAL_LOCATION ]] && jq . <<<$FILE > $FINAL_LOCATION - +[[ -f $FINAL_LOCATION ]] && cat $FILE | jq . > $FINAL_LOCATION