logoalt Hacker News

mikkupikkutoday at 8:07 AM2 repliesview on HN

What's the simple way for a bash script to get the title of the currently focused window? In X this is easy and the bash script will work with every DE. In Wayland you have to write a different solution for each compositor/DE.. Prove me wrong, please.

It shouldn't be hard, all I want to do is fuzzy match window titles to named audio streams in pipewire, but "Oohh noo that's a security flaw!" say the patronizing Wayland developers who care more about making their own lives as developers simple than supporting basic desktop functionality.


Replies

saint_yossariantoday at 11:35 AM

> all I want to do is fuzzy match window titles to named audio streams in pipewire,

> basic desktop functionality

I feel your pain, but find your idea of "basic" functionality amusing.

That said, `pw-dump` / `pactl` will give you client names, which often match the window titles.

show 1 reply
imtringuedtoday at 10:51 AM

> In X this is easy and the bash script will work with every DE. In Wayland you have to write a different solution for each compositor/DE.. Prove me wrong, please.

I don't know what you expect people to prove other than that X and Wayland both have the same problem but since X is so complicated there is only one implementation to begin with, which makes it look like X has solved the problem even though it suffers from exactly the same problem.

show 1 reply