Hyprland Discord Presence is a lightweight daemon that updates your Discord Rich Presence based on the currently active window in Hyprland (a dynamic tiling Wayland compositor). It provides real-time window tracking and can be optionally run in a streaming mode.
- β Automatic Window Tracking β Updates your Discord status based on active windows.
- β Efficient Event Listener β Uses Hyprland's IPC socket instead of brute-force polling.
- β Debounced Updates β Reduces unnecessary Discord API calls.
- β NixOS-Friendly β Easily deployable as a NixOS systemd service.
- β
Optional Streaming Mode β Use
--use-stream-window
flag to enable real-time tracking.
git clone https://github.com/your-username/hyprland-discord-presence.git
cd hyprland-discord-presence
go build -o hypr-discord-presence
./hypr-discord-presence --use-stream-window
Edit /etc/nixos/configuration.nix
and add:
systemd.services.hypr-discord-presence = {
description = "Hyprland Discord Presence Daemon";
after = [ "network.target" "graphical-session.target" ];
wantedBy = [ "default.target" ];
serviceConfig = {
ExecStart = "/path/to/hypr-discord-presence --use-stream-window";
Restart = "always";
RestartSec = 3;
User = "your-username";
Environment = [
"XDG_RUNTIME_DIR=/run/user/1000"
"DISPLAY=:0"
"WAYLAND_DISPLAY=wayland-1"
];
};
};
Then apply changes with:
sudo nixos-rebuild switch
π MIT License