feat(keyboard): multi-layout cycle bind + summer-bar language parity
All checks were successful
Check / eval (push) Successful in 2m59s

SUPER+SHIFT+K → hyprctl switchxkblayout current next, rendered only
when the session layout has a comma — the same gate as the Waybar
language indicator. Bind data is a separate multiLayoutBinds list in
keybinds.nix (still one source); hyprland.nix and the rofi cheatsheet
gate on the identical condition, so bind and cheatsheet cannot drift.
`current` targets the focused keyboard, so per-device-overridden
boards (single layout) are a no-op.

Parity: hyprland/language (with the keyboard glyph) added to both
summer waybar.jsonc whole-swaps + #language in their CSS. Static JSON
cannot eval-gate, so on summer themes the module shows even with one
layout — parity-over-minimalism, deliberate. Found en route:
summer-night has an idle_inhibitor the generated bar lacks (reverse
gap) — folded into backlog item 13.

Also — agent/BACKLOG.md gains items 21-24 from Bernardo's Latitude
5410 hardware QA (waybar crash on theme switch + no respawn; nameless
network-menu rows; a no-update sys-rebuild; Back-everywhere audit),
queued ahead of everything; HARDWARE-QUEUE's snapshot re-test now
carries the "update to >= a47aa3a + relogin" precondition, since
findings 5/6 match the pre-polkit-agent behavior exactly.

Verified: V0 (flake check, both summer JSONs parse) + V1 both
directions (default single-layout build renders no bind; us,de via
extendModules renders bind AND cheatsheet row). V3 cycle check queued.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Bernardo Magri
2026-07-04 14:11:12 +01:00
parent 1e4427f6af
commit f70838c5b5
11 changed files with 130 additions and 21 deletions

View File

@@ -22,14 +22,51 @@ next, in what order*.
## NOW
### 5. Keyboard layouts — cycle bind + summer-bar parity
ROADMAP § Keyboard layouts, remaining bullets: (a) a multi-layout cycle
bind (`hyprctl switchxkblayout` current-device, or xkb `grp:` option)
when >1 session layout, in the cheatsheet; (b) add `hyprland/language`
to the summer-day/night `waybar.jsonc` whole-swaps (parity rule — the
generated bar has it, the static ones don't; gating doesn't translate,
decide the static behavior and note it). **Verify:** V1 + `jq` the
rendered configs; V3 queue the on-hardware cycle check.
*Items 2124: real-hardware QA findings from the Latitude 5410
(Bernardo, 2026-07-04) — bugs found on metal outrank the queue.*
### 21. Waybar crash on theme switch — no respawn
Reported: after a theme switch on the Latitude, Waybar crashed and
never came back (exec-once = no supervisor; a crash orphans the session
until relogin). Two halves: (a) **resilience** — Waybar must respawn on
crash regardless of cause. exec-once a small supervisor loop (restart
with backoff; must not fight `pkill -x waybar` intentional stops), or
re-attempt the systemd user unit with an IPC-readiness gate (the naive
unit raced Hyprland IPC on relogin — see waybar.nix's comment). (b)
**root cause** — the switch path both flips `style.css` (Waybar's
`reload_style_on_change` picks it up) *and* sends SIGUSR2
(`nomarchy-theme-sync`), a double-reload during the config/css symlink
flip; suspect the race crashes Waybar's reload. Consider: drop the
SIGUSR2 when `reload_style_on_change` is on, or replace reload with a
clean restart on switch. **Verify:** V2 (kill waybar in the themed-VM
recipe → respawns; switch theme → bar survives); V3 re-check on the
Latitude.
### 22. Network menu shows nameless/weird entries
Reported: `networkmanager_dmenu` lists entries with no names (likely
hidden-SSID APs rendered as blank rows, possibly other adapters/
duplicate BSSIDs). Investigate its config.ini surface for filtering,
or patch the list source; blank rows in a themed picker read as
breakage. **Verify:** V1 (config renders) — behavior needs Wi-Fi
hardware → V3 on the Latitude.
### 23. `sys-rebuild` — rebuild without updating the lock
Reported: there's no way to rebuild the system *without* `sys-update`'s
`nix flake update` (home-update already skips the lock; the system side
lacks the twin). Add `sys-rebuild` (snapshot-first like sys-update,
rebuild against the current lock, no update) alongside `sys-update`;
document both in README §5 + the motd cheat sheet if it lists them.
**Verify:** V1 + eval that both scripts land on PATH.
### 24. "Back" audit — every list menu ends in ↩ Back
Reported: some submenu items/tools still lack a Back option. The "Back
everywhere" pass covered the hand-rolled dmenu lists at the time; audit
what's been added since (VPN, Display, power-profile, printers…) and
the external/plugin modules (networkmanager_dmenu, rofi-pulse-select,
rofi-calc/emoji modi) — hand-rolled lists get the shared `back` helper;
external modi that can't take an injected row get documented as such
(and Esc always works). **Verify:** V1 + a grep-the-generated-script
audit listing which menus have/lack Back; V3 spot-check.
### 6. Full docs review & restructure
ROADMAP § Full docs review. The roadmap/backlog split is done (this
@@ -100,8 +137,9 @@ supports it, else V3 queue.
### 13. Small niceties batch (one slice per iteration)
Each is a small, self-contained polish item in the existing patterns:
- **Idle-inhibit (caffeine) toggle:** Waybar `idle_inhibitor` module
(blocks hypridle lock/suspend during video/presentations) + summer
whole-swap parity + cheatsheet mention.
(blocks hypridle lock/suspend during video/presentations) in the
GENERATED bar — summer-night already has one (reverse parity gap
found 2026-07-04); add to summer-day too + cheatsheet mention.
- **Low-battery notifications:** the bar colors at 25/10% but nothing
*notifies*; gate on `power.laptop` (poweralertd, or a small upower
watcher consistent with how the bar reads state).