Get Discord push-to-talk working when its keybind recorder captures nothing
The cause (no global key grabs on Wayland, Discord does not implement the GlobalShortcuts portal) is correct, and the record even states that Omarchy sets ELECTRON_OZONE_PLATFORM_HINT globally, but the fix then contradicts that. Omarchy's default/hypr/envs.lua exports BOTH ELECTRON_OZONE_PLATFORM_HINT=wayland and OZONE_PLATFORM=wayland. Blanking only the Electron hint leaves OZONE_PLATFORM=wayland set, so Chromium's Ozone layer still selects the Wayland platform and Discord stays native Wayland. The keybind recorder still captures nothing and the user concludes the record is wrong. The companion record for Electron windows gets this right by unsetting both. This one does not. The .desktop file inherits the same bug. The wpctl push-to-talk alternative is correct (set-mute 0 on press, 1 on release) but is given only in hyprlang, with no 0.55+/Lua form.
Running Discord under XWayland means its screen share can no longer see native Wayland windows or the whole screen. See the xwayland-app-cannot-share-wayland-windows record. You are trading one capability for the other.
Symptom
Push-to-talk and other Discord keybinds do nothing. The Discord keybind recorder will not capture a key at all. Pressing keys in the Keybinds settings page registers nothing.
Cause
Native-Wayland Discord cannot grab global keys. Keyboard input only reaches a focused surface, and Discord does not implement the GlobalShortcuts portal. Under XWayland it can use X11 grabs, which is why the same build works there. Omarchy sets ELECTRON_OZONE_PLATFORM_HINT=wayland globally, so Discord runs native Wayland by default.
Fix
Run Discord under XWayland. Omarchy exports BOTH ELECTRON_OZONE_PLATFORM_HINT=wayland and OZONE_PLATFORM=wayland, so blanking only the first leaves the app on Wayland. Unset both, or force X11 outright:
env -u ELECTRON_OZONE_PLATFORM_HINT -u OZONE_PLATFORM discord
or, more explicit and immune to whatever else is exported:
discord --ozone-platform=x11
If that works, make a second desktop entry rather than editing the packaged one:
cp /usr/share/applications/discord.desktop ~/.local/share/applications/discord-x11.desktop
Edit ~/.local/share/applications/discord-x11.desktop:
Name=DiscordX
Exec=env -u ELECTRON_OZONE_PLATFORM_HINT -u OZONE_PLATFORM /usr/bin/discord
Confirm it worked. The window must show as XWayland:
hyprctl clients -j | jq '.[] | select(.class|test("discord";"i")) | {class, xwayland}'
Alternative that keeps Wayland: bind push-to-talk in Hyprland and have it toggle mute in PipeWire instead of relying on Discord's own grab.
Hyprland <=0.54 / Omarchy 3.x:
bind = , mouse:276, exec, wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 0
bindr = , mouse:276, exec, wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 1
Hyprland 0.55+ / Omarchy 4.x (~/.config/hypr/bindings.lua):
hl.bind("mouse:276", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 0"))
hl.bind("mouse:276", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 1"), { release = true })
Verify
Open Discord Settings -> Keybinds -> Record Keybind and press a key and it is captured. Push-to-talk then works while another window is focused.