From 820f2f88d1533af9fc65f90fd8dd8aba722cee66 Mon Sep 17 00:00:00 2001 From: fred Date: Tue, 23 Aug 2022 14:24:18 +0200 Subject: [PATCH] use tiddlywiki node.js to update TW --- installnot.sh | 6 ++++++ tools/VISA.new.sh | 9 +++++++++ 2 files changed, 15 insertions(+) diff --git a/installnot.sh b/installnot.sh index 8f547a6b..564be48b 100644 --- a/installnot.sh +++ b/installnot.sh @@ -46,6 +46,12 @@ for i in build-essential qrencode jq bc file gawk yt-dlp ffmpeg sqlite dnsutils fi done +### Install tiddlywiki node.js +sudo apt install -y npm +sudo npm install -g tiddlywiki + + + [[ ! $(which kodi) && "$USER" != "xbian" ]] &&\ echo ">>> Installation Kodi + Vstream = VOTRE VIDEOTHEQUE ! <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<";\ sudo apt-get install kodi -y;\ diff --git a/tools/VISA.new.sh b/tools/VISA.new.sh index 50fcda2e..a72a77a7 100755 --- a/tools/VISA.new.sh +++ b/tools/VISA.new.sh @@ -149,6 +149,15 @@ G1PUB=$(cat /tmp/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2) sed -i "s~k2k4r8naeti1ny2hsk3a0ziwz22urwiu633hauluwopf4vwjk4x68qgk~${ASTRONAUTENS}~g" ~/.zen/game/players/$PLAYER/ipfs/.$PeerID/moa/index.html sed -i "s~ipfs.infura.io~tube.copylaradio.com~g" ~/.zen/game/players/$PLAYER/ipfs/.$PeerID/moa/index.html + myIP=$(hostname -I | awk '{print $1}' | head -n 1) + sed -i "s~127.0.0.1~$myIP~g" ~/.zen/game/world/$WISHKEY/index.html + + tiddlywiki --verbose --load ~/.zen/game/players/$PLAYER/ipfs/.$PeerID/moa/index.html \ + --import ~/.zen/Astroport.ONE/templates/data/local.api.json "application/json" \ + --import ~/.zen/Astroport.ONE/templates/data/local.gw.json "application/json" \ + --output ~/.zen/tmp --render "$:/core/save/all" "newindex.html" "text/plain" + [[ -f ~/.zen/tmp/newindex.html ]] && cp ~/.zen/tmp/newindex.html ~/.zen/game/players/$PLAYER/ipfs/.$PeerID/moa/index.html + ## ID CARD convert ~/.zen/game/players/$PLAYER/QR.png -resize 300 /tmp/QR.png convert ${MY_PATH}/../images/astroport.jpg -resize 300 /tmp/ASTROPORT.png