You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: db-version.md
+9-1Lines changed: 9 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -434,4 +434,12 @@ DB graphs are scriptable using https://github.com/logseq/nbb-logseq/tree/feat/db
434
434
435
435
*https://github.com/logseq/logseq/tree/feat/db/deps/db/script - Scripts to query, validate and create any graph
436
436
*https://github.com/logseq/logseq/blob/feat/db/deps/outliner/script/transact.cljs - Script to transact (modify) nodes queried from the commandline
437
-
*https://github.com/logseq/logseq/tree/feat/db/scripts/src/logseq/tasks/db_graph - More complex scripts to generate graphs with all property types or with schema.org's ontology. See [this readme](https://github.com/logseq/logseq/tree/feat/db/scripts#nbb-scripts) for using these.
437
+
*https://github.com/logseq/logseq/tree/feat/db/scripts/src/logseq/tasks/db_graph - More complex scripts to generate graphs with all property types or with schema.org's ontology. See [this readme](https://github.com/logseq/logseq/tree/feat/db/scripts#nbb-scripts) for using these.
438
+
439
+
### Modify a DB Graph
440
+
441
+
On desktop, it is easy to modify an existing DB graph with a script and see the change in Logseq. To do so:
442
+
443
+
1. Press Cmd-S to persist a graph to `~/logseq/graphs/GRAPH-NAME/db.sqlite`.
444
+
2. Modify the db.sqlite with a nbb-logseq script.
445
+
3. Update the app to use the modified db.sqlite by using the `Replace graph with its db.sqlite file` dev command.
0 commit comments