Repository navigation
Self-hosted ZenNotes server 2.96.0, released with ZenNotes desktop 2.96.0. Restore now puts a note back where it was trashed from: the server keeps a record of where each trashed note came from, the same record every ZenNotes app reads. The browser app moves to 2.96.0, so the Tasks filter reads where: queries and the Tasks header counts what each view shows.
Server
- Restore puts a note back where it was trashed from (#100). Moving a note to the trash keeps its subfolder and drops the folder it sat in, so Restore had nothing to go on and sent every note to the notes area: a note trashed from the Archive or Quick Notes came back somewhere it never was. The server now keeps
.zennotes/trash-origins.jsonin the vault, recording which notes in the trash came from the Archive or Quick Notes, and Restore puts each one back there, subfolder and all. A note with no entry (one from the notes area, or trashed before this release) goes to the notes area, as before. - The record follows every move. Renaming a note or a folder in the trash keeps its entry. Moving a note out of the trash by Move or Archive drops it, Move into the trash records it like a trash, and deleting a note or folder in the trash, or emptying the trash, forgets what was there. Moves and deletes from an offline copy's sync keep it right too.
- It never gets in the way. A missing, damaged or newer record reads as empty, so the worst case is a note restored to the notes area. A record that cannot be written is logged and never fails a trash, restore, delete or empty. The record stays on the server: it is not in listings, the sync manifest or the change feed.
- The record format and its rules are one table shared by the desktop app,
zn, the phones, the web app and this server (internal/vault/testdata/trash-origins.cases.json, sha25649f4c83d7c0fbdd831af2d0358212821ef6080e6d88fa3bccdd7964439a887f8), and the server runs every case in it.
Go dependencies are unchanged, so vendorHash is unchanged.
Web client
The bundled browser app moves from 2.95.0 to 2.96.0 (web-2.96.0-web.hc983d7ea9cb4a150, from ZenNotes/zennotes 43683ee9):
- The Tasks filter reads
where:queries. A query that starts withwhere:is split into terms a task has to satisfy together, such aswhere: #proj/test is:openorwhere: due:overdue priority:high -#someday, with the same meaning as inzn tui, so a filter saved in the terminal picks the same tasks in the browser. It works in the list, the calendar, the board, the Timeline and saved filters. A query without the prefix searches as before. - Restore goes back to the Archive or Quick Notes, reading the server's record.
- The Tasks header counts what the view shows: the list its tasks, the calendar its open tasks, the board its cards. A calendar day with nothing under a filter says so, the filter opens folded groups that hold a match, and the filter box widens to fit a long query.
- Move to… never offers a database folder.
Install
Binaries for Linux, macOS and Windows are attached, with SHA256SUMS. Docker: adibhanna/zennotes:2.96.0, 2.96 and latest.
How to test locally
- Run the server on a scratch vault and open it in a browser.
- Make a note in a subfolder, archive it, move it to the trash, then Restore it. Before: it came back in your notes. After: it is in the Archive, in the same subfolder, and
.zennotes/trash-origins.jsonno longer lists it. - Do the same from Quick Notes, and once more after renaming the note while it is in the trash.
- Give two open tasks and one finished task the tag
#proj/test, open Tasks and typewhere: #proj/test is:open: the header reads "2 of N" and the list shows the two open tasks.
Verification
Every check passed on the release commit 00a05cbd (#102): Go tests on Linux, macOS and Windows, the MCP contract, the sync-engine jobs, Docker and Nix (two macOS jobs that never got a runner were re-run and passed). The release workflow (run 46897286021) built the five binaries from 00a05cbd; every binary matches SHA256SUMS, and the manifest matches the pin byte for byte. The macOS arm64 binary was run on a scratch vault: it reports v2.96.0, serves the web app at / and answers /api/vault and /api/capabilities for that vault. A note created at archive/Work/Plan.md and moved to the trash was recorded as archive in .zennotes/trash-origins.json, and Restore put it back at archive/Work/Plan.md and removed the entry. The same browser app is the one desktop 2.96.0 ships.