From eebd3c2875388356edc55a9f17f4222c5b141246 Mon Sep 17 00:00:00 2001 From: fred Date: Thu, 13 Oct 2022 19:50:55 +0200 Subject: [PATCH] =?UTF-8?q?=C3=A9b=C3=A9=20commit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ASTROBOT/PLAYER.refresh.sh | 6 ++++-- ASTROBOT/VOEUX.create.sh | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ASTROBOT/PLAYER.refresh.sh b/ASTROBOT/PLAYER.refresh.sh index e8001844a..56f187204 100755 --- a/ASTROBOT/PLAYER.refresh.sh +++ b/ASTROBOT/PLAYER.refresh.sh @@ -12,6 +12,7 @@ ME="${0##*/}" # Run TAG subprocess: tube, voeu ############################################ echo "## RUNNING PLAYER.refresh" +rm ~/.zen/game/astronautes.txt ## RUNING FOR ALL LOCAL PLAYERS for PLAYER in $(ls ~/.zen/game/players/); do @@ -116,13 +117,14 @@ for PLAYER in $(ls ~/.zen/game/players/); do echo "$PLAYER : http://$myIP:8080/ipns/$ASTRONAUTENS" echo "================================================" +## PUBLISHING ASTRONAUTS LIST +[[ ! $(grep -w "$ASTRONAUTENS" ~/.zen/game/astronautes.txt ) ]] && echo "$PSEUDO:$PLAYER:$ASTRONAUTENS" >> ~/.zen/game/astronautes.txt + done ################################################################# ## IPFSNODEIDE ASTRONAUTES SIGNALING ## ############################ -## PUBLISHING ASTRONAUTS LIST -[[ ! $(grep -w "$ASTRONAUTENS" ~/.zen/game/astronautes.txt ) ]] && echo "$PSEUDO:$PLAYER:$ASTRONAUTENS" >> ~/.zen/game/astronautes.txt ############################ ## TODO EVOLVE TO P2P QOS MAPPING cat ~/.zen/game/astronautes.txt diff --git a/ASTROBOT/VOEUX.create.sh b/ASTROBOT/VOEUX.create.sh index 8fd301251..ec14198b5 100755 --- a/ASTROBOT/VOEUX.create.sh +++ b/ASTROBOT/VOEUX.create.sh @@ -17,7 +17,7 @@ INDEX="$1" [[ ! -f $INDEX ]] && echo "Fichier TW absent. $INDEX" && exit 1 PLAYER="$2" ## IPNS KEY NAME - G1PUB - PLAYER ... -[[ ! $PLAYER ]] && echo "Please provide IPFS publish key" && exit 1 +[[ ! $PLAYER ]] && echo "Please provide IPNS publish key name" && exit 1 ASTRONAUTENS=$(ipfs key list -l | grep -w $PLAYER | cut -d ' ' -f1) [[ ! $ASTRONAUTENS ]] && echo "$PLAYER IPNS INTROUVABLE" && exit 1