breadman: watch bread-theme's palette cache instead of ~/.cache/wal #8

Closed
opened 2026-09-26 12:29:34 +08:00 by Breadway · 6 comments
Owner

breadman/src/theme.rs:33 adds ~/.cache/wal to its watched dirs. After epic PYWAL moves the global palette to a bread-owned path, breadman would stop recolouring on wallpaper change.

  • Watch the new bread-theme cache dir (ideally via a bread-theme path helper, not a hardcoded path).
  • Bump bread-theme tag.
  • Reword pywal mentions in breadpad/breadman README, breadman/ui/src/app.css, breadpad-shared/src/theme.rs, breadpad/src/main.rs.

Part of epic PYWAL.

`breadman/src/theme.rs:33` adds `~/.cache/wal` to its watched dirs. After epic PYWAL moves the global palette to a bread-owned path, breadman would stop recolouring on wallpaper change. - Watch the new bread-theme cache dir (ideally via a bread-theme path helper, not a hardcoded path). - Bump bread-theme tag. - Reword pywal mentions in breadpad/breadman README, `breadman/ui/src/app.css`, `breadpad-shared/src/theme.rs`, `breadpad/src/main.rs`. Part of epic PYWAL.
Author
Owner

PR: #9

breadman now watches bread_theme::palette_cache_dir() instead of a hardcoded ~/.cache/wal. Bumping bread-theme also required passing Typography::default() into the now-two-arg stylesheet() call in breadpad-shared. bread-theme dep points at feature/native-palette for now (needs the release tag before merge). Verified check/clippy/test (workspace) against a temporary local override of the in-progress bread-theme worktree, then reverted the override.

PR: https://git.breadway.dev/Breadway/breadpad/pulls/9 breadman now watches bread_theme::palette_cache_dir() instead of a hardcoded ~/.cache/wal. Bumping bread-theme also required passing Typography::default() into the now-two-arg stylesheet() call in breadpad-shared. bread-theme dep points at feature/native-palette for now (needs the release tag before merge). Verified check/clippy/test (workspace) against a temporary local override of the in-progress bread-theme worktree, then reverted the override.
Author
Owner

Reviewed breadpad#9: approve pending the bread-theme release. The code is correct (watcher now on palette_cache_dir(), stylesheet &Typography call site updated). CI is red only because Cargo.lock does not match the branch dep; reproduced in a clean clone with --locked. After bread-ecosystem#36 is released, re-point both Cargo.toml files to the tag and commit the regenerated lock. Nits in the PR comment: Typography::default() vs active(), and the watcher skipping a not-yet-existing cache dir. Left in review.

Reviewed breadpad#9: approve pending the bread-theme release. The code is correct (watcher now on `palette_cache_dir()`, stylesheet `&Typography` call site updated). CI is red only because Cargo.lock does not match the branch dep; reproduced in a clean clone with `--locked`. After bread-ecosystem#36 is released, re-point both Cargo.toml files to the tag and commit the regenerated lock. Nits in the PR comment: `Typography::default()` vs `active()`, and the watcher skipping a not-yet-existing cache dir. Left in review.
Author
Owner

Pushed nit fixes to feature/drop-pywal: watched_dirs() now creates palette_cache_dir() before the retain(exists) filter so a fresh install's first breadpaper write is seen, and breadpad-shared's build_css() now uses Typography::active() instead of Typography::default() to follow the shell theme's font tokens. Also refreshed Cargo.lock against bread-theme's latest feature/native-palette commit (3758f0c), verified with a fresh-clone cargo build --workspace --locked.

Verified: cargo check --workspace, cargo clippy --workspace --all-targets -- -D warnings, cargo test --workspace, all clean.

PR: #9

Pushed nit fixes to feature/drop-pywal: watched_dirs() now creates palette_cache_dir() before the retain(exists) filter so a fresh install's first breadpaper write is seen, and breadpad-shared's build_css() now uses Typography::active() instead of Typography::default() to follow the shell theme's font tokens. Also refreshed Cargo.lock against bread-theme's latest feature/native-palette commit (3758f0c), verified with a fresh-clone cargo build --workspace --locked. Verified: cargo check --workspace, cargo clippy --workspace --all-targets -- -D warnings, cargo test --workspace, all clean. PR: https://git.breadway.dev/Breadway/breadpad/pulls/9
Author
Owner

Second-round review: the code is correct and CI is green. The watcher now creates the cache dir, and Typography::active() is right. One doc fix is left, plus the relock. Full review: #9

  • README.md:82 says "Falls back to Catppuccin Mocha". That is false: bread-theme falls back to a legacy wal colors.json, then its built-in bread-toned default. This is the same fix breadbar#25 needed.
  • After the bread-ecosystem#36 release: repin breadman/Cargo.toml:33 and breadpad-shared/Cargo.toml:10 to the release tag and commit the regenerated Cargo.lock.

Rework happens on the existing branch feature/drop-pywal, and PR #9 stays open. Do not open a second PR for this key.

Second-round review: the code is correct and CI is green. The watcher now creates the cache dir, and `Typography::active()` is right. One doc fix is left, plus the relock. Full review: https://git.breadway.dev/Breadway/breadpad/pulls/9 - [ ] `README.md:82` says "Falls back to Catppuccin Mocha". That is false: bread-theme falls back to a legacy wal colors.json, then its built-in bread-toned default. This is the same fix breadbar#25 needed. - [ ] After the bread-ecosystem#36 release: repin `breadman/Cargo.toml:33` and `breadpad-shared/Cargo.toml:10` to the release tag and commit the regenerated Cargo.lock. Rework happens on the existing branch feature/drop-pywal, and PR #9 stays open. Do not open a second PR for this key.
Author
Owner

Round-3 update, PR: #9

README.md:82 fixed (falls back to a legacy wal colors.json cache if present, then bread-theme's own built-in bread-toned default, not Catppuccin Mocha). Relocked Cargo.lock against bread-theme's latest feature/native-palette commit. Confirmed neither breadman nor breadpad-shared enables bread-theme's new extract feature and nothing calls palette_from_image/pywal_colors/generate_output, so this crate stays extraction-free as intended (do NOT enable, per instructions).

Verified: cargo build --workspace --locked, cargo test --workspace --locked (all passed), cargo clippy --workspace --all-targets --locked -- -D warnings, matching this repo's actual CI gate.

Round-3 update, PR: https://git.breadway.dev/Breadway/breadpad/pulls/9 README.md:82 fixed (falls back to a legacy wal colors.json cache if present, then bread-theme's own built-in bread-toned default, not Catppuccin Mocha). Relocked Cargo.lock against bread-theme's latest feature/native-palette commit. Confirmed neither breadman nor breadpad-shared enables bread-theme's new extract feature and nothing calls palette_from_image/pywal_colors/generate_output, so this crate stays extraction-free as intended (do NOT enable, per instructions). Verified: cargo build --workspace --locked, cargo test --workspace --locked (all passed), cargo clippy --workspace --all-targets --locked -- -D warnings, matching this repo's actual CI gate.
Author
Owner

Third-round review of PR #9: approved, pending the bread-theme tag (#9 (comment)). Before merging, two steps are needed. First, rebase onto main: the Typography conflict in breadpad-shared/src/theme.rs resolves to main's side both times. Second, repin both bread-theme deps from the branch to the new tag and relock, since lint-pins rejects branch pins. The issue stays in review.

Third-round review of PR #9: approved, pending the bread-theme tag (https://git.breadway.dev/Breadway/breadpad/pulls/9#issuecomment-1384). Before merging, two steps are needed. First, rebase onto main: the Typography conflict in breadpad-shared/src/theme.rs resolves to main's side both times. Second, repin both bread-theme deps from the branch to the new tag and relock, since lint-pins rejects branch pins. The issue stays in review.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Breadway/breadpad#8
No description provided.