Migrate config load/save to bread_utils::tomlcfg; timeout-guard hyprctl calls
config.rs's config_dir/load_doc/save_doc/atomic_write were a byte-for-byte copy of bos-settings/src/config/mod.rs's versions (own doc comment said as much) introduced in the same fix pass that added them there — now both delegate to bread_utils::tomlcfg/bread_utils::atomic instead of each carrying their own copy (path dependency for now, see the TODO in Cargo.toml). Also: services/hyprland.rs::query_json used a bare Command::output() with no timeout, so an unresponsive hyprctl (Hyprland wedged/reloading) could block clients()/monitors()/layers() indefinitely — switched to bread_utils::proc::run_json with a 3s cap. Builds clean; all 8 existing tests pass.
This commit is contained in:
parent
df7f51281a
commit
7b7fe680fe
4 changed files with 33 additions and 59 deletions
|
|
@ -17,3 +17,5 @@ toml = "0.8"
|
|||
# Non-destructive state editing (mirrors bos-settings/src/config/mod.rs).
|
||||
toml_edit = "0.22"
|
||||
async-channel = "2"
|
||||
# TODO(owner): switch to tag-pinned git dependency once bread-utils is merged and tagged, matching the bread-theme pattern
|
||||
bread-utils = { path = "../bread-ecosystem-fix-worktree/bread-utils", features = ["toml"] }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue