feat(audio): prefer dock/HDMI/USB sinks in WirePlumber (#87)
Some checks failed
Check / eval (push) Has been cancelled

Raise priority.session for HDMI/DisplayPort (1100) and USB (1050) ALSA
outputs so the default sink follows dock plug/unplug; built-in analog
wins again when externals disappear. Rules live in
modules/nixos/dock-audio-rules.nix; checks.dock-audio covers the contract.

Verified: V2 — flake check --no-build; checks.dock-audio green.
V3 pending: HARDWARE-QUEUE #87 real HDMI/USB-dock hotplug.
This commit is contained in:
Bernardo Magri
2026-07-11 10:36:07 +01:00
parent 27f18e4ccc
commit f47903a6a6
9 changed files with 125 additions and 8 deletions

View File

@@ -55,10 +55,6 @@ runtime-computed `resume_offset` into the boot cmdline, and the dev box runs
exactly this layout (`/proc/cmdline` verified) but isn't Nomarchy. Steps in
HARDWARE-QUEUE. Close #76 on PASS.
### 87. Dock audio sink follows plug/unplug (`VISION § C`)
Default audio sink: dock sink on plug, internal on unplug (WirePlumber
policy or udev hook). Complements #86; can ship independently.
## LATER
- **Wallpapers artifact split** (ROADMAP § Faster switches — decided,
@@ -111,8 +107,8 @@ high-ROI, etc.) live in the journal + ROADMAP — not here.*
2026-07-10). Keep #59 commented install guidance; no
`nomarchy.hardware.nvidia.*` until a hybrid maintainer + queue.
_(#80#83 + #85#86 shipped 2026-07-11. Remaining dock slice: **#87**
dock audio. #86 V3 clamshell on real external display → HARDWARE-QUEUE.)_
_(#80#83 + #85#87 shipped 2026-07-11. Dock V3 residuals: #86
clamshell + #87 audio on real hardware → HARDWARE-QUEUE.)_
### v1.0 pointer

View File

@@ -19,6 +19,13 @@ the **T14s** (webcam case).
— should suspend as usual. Optional: with a docked display-profile
(`eDP-1` disable), confirm clamshell layout still looks right after
lid close. Pass = no surprise suspend when docked.
- [ ] **#87 dock audio sink follow** — V2 asserts WirePlumber
`90-nomarchy-dock-audio` rules (HDMI/USB priority). On a laptop
with HDMI or USB-dock audio: play sound on speakers, plug external
audio → default sink should move to HDMI/dock (`wpctl status` shows
`*` on the external sink); unplug → `*` returns to built-in.
Manual `wpctl set-default` still works; Bluetooth may outrank dock
(by design). Pass = auto switch without menu intervention.
- [ ] **#55 fingerprint enroll on real reader** — with
`nomarchy.hardware.fingerprint.enable` and a physical reader: System
Fingerprint Enroll a finger; List shows it; Verify succeeds; optional

View File

@@ -19,6 +19,17 @@ Template:
---
## 2026-07-11 — #87 dock audio sink priority
- **Task:** NEXT #87 — default audio follows dock plug/unplug.
- **Did:** WirePlumber `90-nomarchy-dock-audio` (HDMI/DP session prio
1100, USB 1050) via `modules/nixos/dock-audio-rules.nix` + default.nix
pipewire. `checks.dock-audio` pure rule asserts + conf-file VM. V3
hotplug steps in HARDWARE-QUEUE. Closed #87.
- **Verified:** **V2**`nix flake check --no-build`; `checks.dock-audio`
green (pure rule asserts + conf installed under wireplumber.conf.d).
- **Pending:** V3 real HDMI/USB-dock hotplug (HARDWARE-QUEUE).
- **Next suggestion:** QA sweep or LATER wallpapers split if promoted.
## 2026-07-11 — #86 clamshell HandleLidSwitchDocked
- **Task:** NEXT #86 — lid closed + external monitor must not suspend.
- **Did:** Explicit `HandleLidSwitchDocked=ignore` in