48 lines
1.1 KiB
Markdown
48 lines
1.1 KiB
Markdown
# Mastodon Bookmarks Archive
|
|
|
|
_A small Janet script to archive all your Mastodon bookmarks in Markdown files._
|
|
|
|
Because Mastodon posts can disappear for a variety of reasons (deletion, defederation, server instance shutdown, ...), it is safer to archive your bookmarks.
|
|
|
|
Each Markdown file will contain:
|
|
- A link to the original post
|
|
- The author's handle
|
|
- The post's content in HTML
|
|
- The media attachments locally downloaded
|
|
- If available, the alt text for each media
|
|
|
|
Most of these values will be in the form of `key:: value` for easy integration with Obsidian's plugin Dataview. A sample script is available [here](./dataview-query.js)
|
|
|
|
## Setup & Run
|
|
|
|
- Get an access token for your Mastodon account
|
|
|
|
![](image1.png)
|
|
![](image2.png)
|
|
|
|
- Run the program
|
|
|
|
```sh
|
|
$ ./mastodon-bookmarks YOUR_APP_TOKEN
|
|
```
|
|
|
|
## Development
|
|
|
|
- Clone this repository
|
|
- Install Janet and jpm https://janet-lang.org/
|
|
- `jpm deps --local`
|
|
|
|
```sh
|
|
$ janet main.janet YOUR_APP_TOKEN
|
|
```
|
|
|
|
## Build binary
|
|
|
|
```sh
|
|
$ jpm build
|
|
```
|
|
|
|
## LICENSE
|
|
|
|
Licensed under [GPL-3](https://www.tldrlegal.com/license/gnu-general-public-license-v3-gpl-3).
|