Persist and reload live UI preferences #8

Closed
opened 2026-11-16 14:39:24 +00:00 by aaron · 0 comments
Owner

Story

As a TrueNAS user, I want to keep preference changes across runs so that monitoring fits my workflow.

Context

Parent scope: #7.

Reuse src/config.rs comment-preserving TOML edits and atomic saves. Feature-specific fields belong to the related feature issues.

Upstream: btop 5d03929a.

Acceptance criteria

  • Apply validated UI preferences without losing server sessions.
  • Save preference changes while preserving comments, unrelated values, servers and certificate trust.
  • Support save-on-exit and Ctrl-R config reload; retain the existing immediate saving of server/trust changes.
  • Preserve config path resolution and environment override precedence.
  • Invalid reloads or failed writes report an error and leave the prior valid settings and file intact.
  • Test save/reload, disabled save-on-exit, environment overrides, invalid data and write failures.

Validation

Run focused tests through mise run test --filter <name> and relevant existing mise format/lint tasks. Record interactive or platform checks required by this issue; report anything untested.

Dependencies

No unfinished prerequisites. Start from the approved parent scope.

## Story As a TrueNAS user, I want to keep preference changes across runs so that monitoring fits my workflow. ## Context Parent scope: #7. Reuse src/config.rs comment-preserving TOML edits and atomic saves. Feature-specific fields belong to the related feature issues. Upstream: [btop 5d03929a](https://github.com/aristocratos/btop/tree/5d03929a45e0720a4c8e2d189360ff1eb9ce1731). ## Acceptance criteria - [ ] Apply validated UI preferences without losing server sessions. - [ ] Save preference changes while preserving comments, unrelated values, servers and certificate trust. - [ ] Support save-on-exit and Ctrl-R config reload; retain the existing immediate saving of server/trust changes. - [ ] Preserve config path resolution and environment override precedence. - [ ] Invalid reloads or failed writes report an error and leave the prior valid settings and file intact. - [ ] Test save/reload, disabled save-on-exit, environment overrides, invalid data and write failures. ## Validation Run focused tests through `mise run test --filter <name>` and relevant existing mise format/lint tasks. Record interactive or platform checks required by this issue; report anything untested. ## Dependencies No unfinished prerequisites. Start from the approved parent scope.
aaron added this to the v0.2.0 milestone 2026-11-16 14:41:41 +00:00
aaron closed this issue 2026-11-16 17:21:14 +00:00
Sign in to join this conversation.
No description provided.