dymokomi/luce-db
Source of release 0.5.1
from luce_db.db import Database
from luce_prism.prism import Value
pub func main(arguments: list[str]) -> int!:
let database = Database.open(arguments[0], "secret")
let tx = database.begin()
tx.add("/notes", "file")
tx.set("/notes", "text", Value.text("hello"))
_ = tx.commit()
let snap = database.snapshot()
assert(snap.get("/notes", "text").text_at() == "hello")
print("PASS Luce database facade over prism.Store")
return 0