niri: propagate XDG_CURRENT_DESKTOP to systemd-user and dbus
The niri 'environment' block only affects processes niri spawns directly. Apps launched via dbus activation or systemd-user (most .desktop launches go through one of these) get systemd-user's env, which still has bare 'niri' — set by niri-session BEFORE niri itself runs. Adding a one-shot spawn-at-startup that re-imports XDG_CURRENT_DESKTOP from niri's env into both systemd-user and dbus-activation, after niri starts. Future dbus-activated apps will see niri:GNOME. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -35,6 +35,7 @@ environment {
|
||||
XDG_CURRENT_DESKTOP "niri:GNOME"
|
||||
}
|
||||
|
||||
spawn-at-startup "sh" "-c" "systemctl --user import-environment XDG_CURRENT_DESKTOP && dbus-update-activation-environment XDG_CURRENT_DESKTOP"
|
||||
spawn-at-startup "waybar"
|
||||
spawn-at-startup "mako"
|
||||
spawn-at-startup "awww-daemon"
|
||||
|
||||
Reference in New Issue
Block a user