Implement CLI store using Deno store

This commit is contained in:
Zef Hemel
2023-08-04 21:17:36 +02:00
parent ba8625cbf1
commit bc561eb723
5 changed files with 69 additions and 82 deletions
+6 -6
View File
@@ -30,10 +30,10 @@ Depending on where these attributes appear, they attach to different things. For
Example query:
<!-- #query page where name = "Attributes" -->
|name |lastModified |contentType |size|perm|pageAttribute|
|----------|-------------|-------------|----|--|-----|
|Attributes|1691165890257|text/markdown|1609|rw|hello|
<!-- #query page where name = "Attributes" select name, pageAttribute -->
|name |pageAttribute|
|----------|-----|
|Attributes|hello|
<!-- /query -->
This attaches an attribute to an item:
@@ -45,7 +45,7 @@ Example query:
<!-- #query item where page = "Attributes" and itemAttribute = "hello" -->
|name|itemAttribute|page |pos |
|----|-----|----------|----|
|Item|hello|Attributes|1079|
|Item|hello|Attributes|1106|
<!-- /query -->
This attaches an attribute to a task:
@@ -57,5 +57,5 @@ Example query:
<!-- #query task where page = "Attributes" and taskAttribute = "hello" -->
|name|done |taskAttribute|page |pos |
|----|-----|-----|----------|----|
|Task|false|hello|Attributes|1355|
|Task|false|hello|Attributes|1382|
<!-- /query -->
+14 -14
View File
@@ -20,21 +20,21 @@ Hadnt we mentioned [[Markdown]] yet? Yeah, thats the markup language you
You will notice this whole page section is wrapped in a strange type of block. This is a SilverBullet specific feature called a [[🔌 Directive]] (in this case `#use`). There are various types of directives, and while were not keeping score, likely the coolest ones are [[🔌 Directive/Query|queries]] — so you should definitely look into those.
Dont believe me, check this out, heres a list of (max 10) pages in your space ordered by last modified date, it updates (somewhat) dynamically 🤯. Create some new pages and come back here to see that it works:
Dont believe me, check this out, heres a list of (max 10) pages in your space ordered by name, it updates (somewhat) dynamically 🤯. Create some new pages and come back here to see that it works:
<!-- #query page select name order by lastModified desc limit 10 -->
|name |
|------------------|
|🔌 Directive/Query|
|Attributes |
|Getting Started |
|🔌 Core/Tags |
|🔌 Github |
|🔌 Mattermost |
|🔌 Git |
|🔌 Ghost |
|🔌 Share |
|Install |
<!-- #query page select name order by name limit 10 -->
|name |
|---------------|
|API |
|Attributes |
|Authelia |
|Authentication |
|CHANGELOG |
|Cloud Links |
|Deployments |
|Federation |
|Frontmatter |
|Getting Started|
<!-- /query -->
That said, the directive used wrapping this page section is `#use` which uses the content of another page as a template and inlines it. Directives recalculate their bodies in two scenarios: