TW in IPFS acts as a distributed object storage database.

This commit is contained in:
fred 2024-04-22 20:10:43 +02:00
parent 1ef36f23c5
commit 147215cc55
7 changed files with 3179 additions and 11 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
.env
*.pyc
__pycache__
tiddlywiki.html

View File

@ -132,8 +132,8 @@ for PLAYER in ${PLAYERONE[@]}; do
</style></head><body><a href='$myIPFS/ipns/${ASTRONAUTENS}'>TW LOADING TIMEOUT</a>" > ~/.zen/tmp/result
echo "<br>------------------------------------------------" >> ~/.zen/tmp/result
echo "<br>" >> ~/.zen/tmp/result
echo "<br><a href='${myIPFS}/ipfs/${LASTCHAIN}'>TW[-1]</a>: /ipfs/${LASTCHAIN}" >> ~/.zen/tmp/result
echo "<br><a href='${myIPFS}/ipfs/${NOWCHAIN}'>TW[0]</a>: /ipfs/${NOWCHAIN}" >> ~/.zen/tmp/result
echo "<br><a href='${myIPFS}/ipfs/${LASTCHAIN}'>[yesterday]</a>: /ipfs/${LASTCHAIN}" >> ~/.zen/tmp/result
echo "<br><a href='${myIPFS}/ipfs/${NOWCHAIN}'>[today]</a>: /ipfs/${NOWCHAIN}" >> ~/.zen/tmp/result
echo "<br>" >> ~/.zen/tmp/result
echo "<br> %%% WARNING %%% $try TRY LEFT %%%" >> ~/.zen/tmp/result
echo "<br>------------------------------------------------" >> ~/.zen/tmp/result

View File

@ -0,0 +1,7 @@
[
{
"title": "/TEST/ForemostPoets-Moonraker.mp3",
"text": "<audio controls><source src='/ipfs/Qmc799UU3zqFojnR13qSiJYKx8mKPXJ3CXMgKyLGvVndUD' type='audio/mpeg'>Your browser does not support the audio element.</audio>",
"tags": "mp3"
}
]

View File

@ -22,9 +22,11 @@ if [[ -s ~/.zen/tmp/${MOATS}.html ]]; then
echo "Tiddler deleted successfully."
cp ~/.zen/tmp/${MOATS}.html ${TW}
rm ~/.zen/tmp/${MOATS}.html
echo "Updated TiddlyWiki: ${TW}"
echo "Updated TiddlyWiki:
${TW}"
else
echo "ERROR: Cannot delete $TITLE from $TW"
echo "ERROR: Cannot delete $TITLE from
$TW"
exit 1
fi

View File

@ -28,10 +28,9 @@ if [[ -s /tmp/${MOATS}.html ]]; then
cp /tmp/${MOATS}.html ${TW}
rm /tmp/${MOATS}.html
rm "${TIDDLER}.tmp"
echo "Updated TiddlyWiki: ${TW}"
echo "Temporary file: /tmp/${MOATS}.html"
echo "Updated TiddlyWiki:
${TW}"
else
echo "ERROR: Unable to import ${TIDDLER} into ${TW}"
exit 1
fi

View File

@ -1,9 +1,19 @@
provide elemental TW interactions
TiddlyWiki acts as a distributed object database
this scripts provides elemental TW interactions
* Import a Tiddler (json) in a TiddliWiki
```./import_tiddler.sh tiddlywiki.html ForemostPoets-Moonraker.json```
* import_tiddler.sh TW TIDDLER
https://talk.tiddlywiki.org/t/how-to-add-extract-modify-tiddlers-from-command-line-to-do-ipfs-media-transfer/4345?u=papiche
* delete_tiddler.sh TW QUERY
* Delete a Tiddler (title) from a TiddliWiki
```./delete_tiddler.sh tiddlywiki.html "/TEST/ForemostPoets-Moonraker.mp3"```
https://talk.tiddlywiki.org/t/how-to-filter-and-delete-multiple-tiddlers/4950
add more complex queries ....
you can add more complex queries ....

3149
RUNTIME/TW/twsector.html Normal file

File diff suppressed because one or more lines are too long