diff --git a/doc/A Solution to the Angel Problem.pdf b/doc/A Solution to the Angel Problem.pdf new file mode 100644 index 0000000..b0de2f4 Binary files /dev/null and b/doc/A Solution to the Angel Problem.pdf differ diff --git a/zen/ssb_INIT.sh b/zen/ssb_INIT.sh index 771d7e8..0e3a073 100755 --- a/zen/ssb_INIT.sh +++ b/zen/ssb_INIT.sh @@ -118,10 +118,18 @@ export LANG=C.UTF-8 #attipix DUNITERNODE=$($MY_PATH/tools/duniter_getnode.sh) [[ $DUNITERNODE ]] && g1balance=$(silkaj -p $DUNITERNODE balance $g1pub 2>&1) || g1balance=$(silkaj balance $g1pub 2>&1) + # SSB PUBLISH G1 wallet silkaj balance -INLINE=$(node -p "JSON.stringify(process.env.g1balance)") +# TODO FIND WHY THIS ***** COMA , IS EVERYWHERE +json_escape () { + printf '%s' "$1" | python -c 'import json,sys; print(json.dumps(sys.stdin.read()))' +} +INLINE=$(json_escape "$g1balance") [[ $INLINE ]] && sbotc publish '{"type":"post","text":'$INLINE'}' +#INLINE="${g1balance@Q}" +#[[ $INLINE ]] && sbotc publish '{"type":"post","text":"'$INLINE'"}' + echo " _ _ / \|_) _ _ _| _