Skip to content

add note history (timeline + restore) across core and clients #179

Description

@haribo

Per-note version timeline with restore. Full design: docs/design/note-history.md.

Why

Notes are Automerge CRDT docs that already retain every change (used for sync),
so a history/restore feature needs no new stored data, no wire change, and does
not affect the zero-knowledge relay — it is a read-only derivation done on-device.

Locked decisions

  • Version boundary = device change OR ≥ 5 min idle gap between changes.
  • Zero-diff dedup only (drop a boundary only if its content equals the previous
    kept version). Never drop for "small" diffs.
  • Retention: 100 most recent versions per note — a display/derivation cap, NOT a
    storage bound. Underlying ops are kept, so the cap is reversible.
  • Scope of a version: title, body, tags, folder. Restore replaces the whole set
    as a forward, merge-safe change (itself a new history entry).

Sub-issues

  • document the note-history design (docs/design/note-history.md)
  • implement note history in core (note_history / note_at / restore) + tests
  • add pn history / --at / restore to the CLI
  • add a history timeline + restore to the GUI
  • add a history screen + restore to Android (mockup-first)

Out of scope

Operation compaction/pruning (own ADR), diff/blame view, per-field or partial
restore, branching/named versions, history search.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: featurenew feature or improvement

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions