Navigator refactor (#648)

Navigation refactor
This commit is contained in:
Zef Hemel
2024-01-24 11:58:33 +01:00
committed by GitHub
parent 9fa52e43e0
commit aaacec6d61
25 changed files with 360 additions and 263 deletions
+3 -3
View File
@@ -4,7 +4,7 @@ This enables a few things:
* **Linking and browsing** to other publicly hosted SilverBullet spaces (or websites adhering to its [[API]]). For instance the [[!silverbullet.md/CHANGELOG|SilverBullet CHANGELOG]] without leaving the comfort of your own SilverBullet client.
* **Reusing** content from externally hosted sources, such as:
* _Templates_, e.g. by federating with `silverbullet.md/template` will give you access to the example templates hosted there without manually copying and pasting them and automatically pull in the latest version. So you can, for instance, use `render [[!silverbullet.md/template/page]]` to use the [[Library/Core/Query/Page]] template. See [[Libraries]] for more on this use case.
* [[Libraries]] synchronization. By federating with `silverbullet.md/Library/Core`, you will get you access to the templates hosted there without copying ({[Library: Import]}ing) them and automatically pull in the latest versions.
* _Data_: such as tasks, item, data hosted elsewhere that you want to query from your own space.
**Note:** Federation does not support authentication yet, so all federated spaces need to be unauthenticated and will be _read-only_.
@@ -17,10 +17,10 @@ To synchronize federated content into your client, you need to list these URIs i
```yaml
federate:
- uri: silverbullet.md/template
- uri: silverbullet.md/Library/Core/
```
This will synchronize all content under `!silverbullet.md` with a `template` prefix (so all templates hosted there) locally.
This will synchronize all content under `!silverbullet.md` with a `Library/Core/` prefix (so all templates hosted there) locally.
Currently, content can only be synchronized in read-only mode, so you can not edit the synchronized files. This will likely change in the future.
+2 -2
View File
@@ -20,7 +20,7 @@ For your first run, you can run the following:
# Create a local folder "space" to keep files in
$ mkdir -p space
# Run the SilverBullet docker container in the foreground
$ docker run -it -p 3000:3000 -v ./space:/space zefhemel/silverbullet
$ sudo docker run -it -p 3000:3000 -v ./space:/space zefhemel/silverbullet
```
This will run SilverBullet in the foreground, interactively, so you can see the logs and instructions.
@@ -49,7 +49,7 @@ $ docker kill silverbullet
# Remove the old container
$ docker rm silverbullet
# Start a fresh one (same command as before)
$ docker run -d --restart unless-stopped --name silverbullet -p 3000:3000 -v ./space:/space zefhemel/silverbullet
$ docker run -d --restart unless-stopped --name silverbullet -p 3000:3000 -v $PW/space:/space zefhemel/silverbullet
```
Since this is somewhat burdensome, it is recommended you use a tool like [watchtower](https://github.com/containrrr/watchtower) to automatically update your docker images and restart them. However, if we go there — we may as well use a tool like _docker compose_ to manage your containers, no?