Hello ๐ I'm trying to inspect the output of wpctl status in order to find out IDs and switch between them. The use case is cycling between my headset and a secondary Bluetooth device
However the box characters found in the output make the usual paragraph awk commands not very effective
With a few irrelevant part cut out, off that output:
PipeWire 'pipewire-0' [0.3.75, angrybacon@maestro, cookie:4815162342]
โโ Clients:
...
Audio
โโ Devices:
โ 38. Navi 21/23 HDMI/DP Audio Controller [alsa]
โ 39. Built-in Audio [alsa]
โ 79. My Bluetooth Headset [bluez5]
โ 79. Secondary Bluetooth Device [bluez5]
โ
โโ Sinks:
โ 40. Navi 21/23 HDMI/DP Audio Controller Digital Stereo (HDMI 2) [vol: 0.45]
โ 41. Built-in Audio Digital Stereo (IEC958) [vol: 0.50]
โ * 78. Bluetooth Headset [vol: 0.55]
โ 92. Secondary Bluetooth Device [vol: 0.31]
โ
โ ...
โ
โโ Streams:
...
...
Video
โโ Devices:
โ ...
โโ Streams:
This is the part that I'm looking for:
โ 40. Navi 21/23 HDMI/DP Audio Controller Digital Stereo (HDMI 2) [vol: 0.45]
โ 41. Built-in Audio Digital Stereo (IEC958) [vol: 0.50]
โ * 78. Bluetooth Headset [vol: 0.55]
โ 92. Secondary Bluetooth Device [vol: 0.31]
Although only 78 and 92 are relevant and I'm not sure it's possible to differentiate physical devices only but I can focus on that issue later