about summary refs log tree commit diff
path: root/modules/user/sternenseemann
diff options
context:
space:
mode:
authorsternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org>2021-04-16 16:14:55 +0200
committersternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org>2021-04-16 16:16:06 +0200
commit24486fb03542db5e5df0f42b7237bd1008d11a37 (patch)
treea3078254e9183eef69b0dfcb4bb431a5aa7e28e6 /modules/user/sternenseemann
parentfbe89b55c8eb38d5519987d51354304a1e5363e1 (diff)
modules/sternenseemann/sway: work around new screensharing issue
Sway updates it's WAYLAND_DISPLAY variable in a way dbus doesn't pick up
on. Fix is taken from here:
https://github.com/NixOS/nixpkgs/issues/119445#issuecomment-820507505
Diffstat (limited to 'modules/user/sternenseemann')
-rw-r--r--modules/user/sternenseemann/services/sway.nix6
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/user/sternenseemann/services/sway.nix b/modules/user/sternenseemann/services/sway.nix
index f34cf194..12070244 100644
--- a/modules/user/sternenseemann/services/sway.nix
+++ b/modules/user/sternenseemann/services/sway.nix
@@ -9,7 +9,10 @@ let
     ;
 
   bins = (getBins pkgs.pulseaudioLight [ "pactl" ])
-      // (getBins pkgs.dbus [ "dbus-run-session" ])
+      // (getBins pkgs.dbus [
+        "dbus-run-session"
+        "dbus-update-activation-environment"
+      ])
       // (getBins cfg.package [ "sway" ])
       // (getBins pkgs.i3status [ "i3status" ])
       // (getBins pkgs.brightnessctl [ "brightnessctl" ])
@@ -160,6 +163,7 @@ in {
       "sway/config".text = ''
         # correct DPI after hotplugging
         exec ${pkgs.xorg.xrdb}/bin/xrdb -load ${dpiXresources}
+        exec ${bins.dbus-update-activation-environment} WAYLAND_DISPLAY
 
         # set the one true modifier
         set $mod Mod4