Skip to content

docs: full documentation overhaul — user manual, tutorials, and developer docs - #13

Merged
Sbussiso merged 3 commits into
masterfrom
docs-overhaul
Jul 4, 2026
Merged

docs: full documentation overhaul — user manual, tutorials, and developer docs#13
Sbussiso merged 3 commits into
masterfrom
docs-overhaul

Conversation

@Sbussiso

@Sbussiso Sbussiso commented Jul 4, 2026

Copy link
Copy Markdown
Contributor

Stacked on #11 (retargets to master when it merges).

docs/manual/ — a real user manual, written for non-technical readers:

  • 10 guides (getting started → searching → images/Explore/viewer → vault → folders & ZIM/ZIP archives → AI summaries → bookmarks → full Settings tour → Linux & Docker → troubleshooting) and 4 step-by-step tutorials (first search, offline Wikipedia, private vault, AI with Ollama).
  • 38 screenshot placeholders with stable filenames, compiled into SCREENSHOTS.md — a session-grouped shot list with exact capture instructions, ready to work through. Images go in docs/manual/img/, which is deliberately outside the binary's embed globs.

docs/dev/ — developer docs: architecture (verified against src/), a route-by-route HTTP API reference, frontend conventions (XSS discipline, the animation fill-mode rule, the landing-demo replica contract), and the dev workflow.

Wiring: README Documentation section; landing nav + footer link the manual. Every internal page link checked (0 broken); UI labels fact-checked against templates/ and static/js/.

🤖 Generated with Claude Code

Sbussiso and others added 3 commits July 4, 2026 10:42
…raceful SIGTERM

The server side already compiled and tested green on Linux (ubuntu CI);
this makes it actually usable there, with zero changes to any Windows
code path (all edits are cfg(unix)-gated, env-gated, or new CI jobs):

- release.yml: new independent `linux-tarball` job — builds x86_64,
  bundles the pinned Meilisearch (same version as the MSI), smoke-tests
  the packaged binary (boot + HTTP + SIGTERM), and attaches
  SearchBox-<ver>-x86_64-linux.tar.gz + .sha256 to the release. No
  `needs:` edge; a Linux failure can never block the MSI legs, and the
  asset name can't collide with the updater/winget `.msi` matching.
- Fixed Docker: the app now honors MEILI_MASTER_KEY when set. Since the
  v0.3.16 key rotation the app generated its own key and never read the
  env var the container starts Meilisearch with — every Meili call in
  Docker was rejected. Env absent (Windows/native) → behavior unchanged.
- SIGTERM handling (cfg(unix)): `docker stop` and systemd stops now do
  the same graceful drain as Ctrl-C instead of hanging as PID 1 until
  SIGKILL and orphaning the sidecar. Verified: TERM → clean exit in ~1s.
- Meilisearch discovery on unix falls back to /usr/local/bin, /usr/bin,
  /opt/meilisearch, ~/.cargo/bin after the sibling check. Windows stays
  sibling-only (the MSI guarantees it).
- Linux data dir: XDG_DATA_HOME/searchbox (else ~/.local/share) unless
  running from a cargo target/ dir — no more scattering searchbox.db,
  vault/ and meili_data/ into whatever cwd the app was launched from.
  Windows branch untouched.
- /api/update/check returns no download_url off Windows, so Settings
  hides the in-app Install button (the apply endpoint was a stub there).
- Inlined three format! args that clippy 1.88 now rejects (-D warnings)
  in untouched files, so CI stays green when its toolchain catches up.
- Docs: README native-Linux section, BUILD.md tarball/Docker-key notes,
  CHANGELOG entries.

Verified: cargo check debug+release and fmt on Windows; cargo check,
clippy -D warnings, and the full 61-test suite in a rust:1.88 Linux
container; end-to-end packaged-binary smoke test (boot, /login 200,
SIGTERM graceful drain) in the same container.
…oper docs

New docs/manual/ — written for non-technical readers, screenshot-guided:
- Guides: getting started, searching (the :: filter language, syntax
  colors), images & Explore & the viewer, the private vault, folders &
  archives (ZIM/ZIP), AI summaries, bookmarks & history, a full Settings
  tour, Linux & Docker, and a problem→cause→fix troubleshooting page.
- Tutorials: your first search, offline Wikipedia (Kiwix ZIM), lock your
  tax documents in the vault, and free local AI summaries with Ollama.
- SCREENSHOTS.md: a session-grouped shot list — every image placeholder
  in the manual with exact capture instructions and stable filenames
  (images land in docs/manual/img/, which is NOT embedded in the binary).

New docs/dev/ — for developers: architecture (process model, Meili
sidecar, storage layout, auth, indexing pipeline, updater, embedding),
the HTTP API surface (verified route-by-route against src/routes/),
frontend conventions (XSS discipline, animation fill-mode rule, the
demo-replica contract), and the local dev workflow.

Wiring: README gains a Documentation section; the landing page nav and
footer link the manual. All internal page links verified (0 broken);
every UI label fact-checked against templates/ and static/js/.
CI run #82 (cargo audit job) failed: 6 vulnerabilities, all from two
freshly-published RUSTSEC advisories (2026-06-29) on quick-xml:
  - RUSTSEC-2026-0194: quadratic-time duplicate-attribute-name check
  - RUSTSEC-2026-0195: unbounded namespace-decl allocation → memory DoS

Three copies of quick-xml were flagged in Cargo.lock:
  - 0.36.2 — our DIRECT dep, used in read_docx to parse uploaded DOCX.
    Reachable + attacker-controlled input → bumped to 0.41.0 (fixed).
    Adapted the one breaking API change: BytesText::unescape() was
    removed in 0.41; replaced with xml10_content() (decodes + unescapes
    + normalizes EOLs; DOCX document.xml is UTF-8 so decode errors are
    unreachable).
  - 0.31.0 — transitive via calamine 0.26.1 (xlsx/ods reader). DoS-only,
    self-DoS by the authenticated uploader. Cannot bump: calamine 0.26
    pins ^0.31; the 0.26→0.35 jump's API churn risks the extractor, so
    it's a tracked follow-up, not a triage fix. Documented + ignored.
  - 0.39.4 — transitive via wayland-scanner ← rfd, which is
    cfg(windows)-gated. Not compiled on the Linux server/CI build →
    lockfile-only, no reachable code path. Documented + ignored.

.cargo/audit.toml gains the two advisory IDs with full reasoning, in
the repo's existing documented-ignore convention. Verified locally:
cargo fmt --check, cargo clippy -D warnings, cargo test (61 passed),
and cargo audit all pass.

Follow-up (out of scope here): upgrade calamine 0.26 → 0.35 to clear
the last transitive quick-xml 0.31.0 and drop the ignore entries.
@Sbussiso
Sbussiso changed the base branch from linux-support to master July 4, 2026 23:05
@Sbussiso
Sbussiso merged commit 79e923d into master Jul 4, 2026
2 checks passed
@Sbussiso
Sbussiso deleted the docs-overhaul branch July 4, 2026 23:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant