A collection of Earthstar scripts for reading, writing, syncing, and archiving share data.
It's like a CLI, but better: you can read, modify, and extend the available scripts so they're just the way you want them.
All these scripts pull their settings from the same source, so you can reuse a keypair and all your favourite shares and servers between them.
All share replica data is persisted to the filesystem in share_data
.
- Clone this repository
- Install the Deno runtime (Instructions)
- Test it all works with
deno run scripts/new_author.ts suzy
Add the URL of a server to the shared settings so that it can be synced with.
Adds an existing share to the shared settings so that other scripts can use it. The first argument is the URL to be saved.
Archives a share replica's data to a zip file. You can then put that archive on a USB key and give it to a friend for syncing, or back it up.
Display the current author keypair saved to shared settings.
Forget the current author keypair saved to shared settings.
Lists all authors from a share replica.
Lists all document paths from a share replica.
List all servers saved to shared settings.
List all shares saved to shared settings.
Generates a new author keypair from a shortname and adds it to shared settings for other scripts to use. The sole argument of this script is the four character shortname used in the new keypair.
Generates a new share keypair from a name and adds it to shared settings for other scripts to use.
Removes a server from the list of servers known by SharedSettings
.
Removes a share from the list of known shares.
Write an attachment to your filesystem.
Take an existing author keypair and save it to the shared settings for other scripts to use.
Prints some info about a share replica.
Displays the secret of a chosen share.
Takes a zipped share archive, and syncs it with our own data for that share. Optionally updates the zipped archive. Useful for when you get that USB key from your friend.
Sync the contents of a filesystem directory with a share replica.
Sync all known shares with all known servers (only shares held in common by both sides will be synced).
Sync one share replica with one Earthstar server.
Write some data to a share replica with free-form text or a file on the filesystem.