slack: force it to use Wayland
This commit is contained in:
@@ -9,9 +9,21 @@
|
||||
# -> presumably: new slack instance locates ~/.config/Slack/SingletonSocket;
|
||||
# forwards the auth details to existing application
|
||||
#
|
||||
{ ... }:
|
||||
{ lib, pkgs, ... }:
|
||||
{
|
||||
sane.programs.slack = {
|
||||
packageUnwrapped = pkgs.slack.overrideAttrs (upstream: {
|
||||
# fix to use wayland instead of Xwayland:
|
||||
# - replace `NIXOS_OZONE_WL` non-empty check with `WAYLAND_DISPLAY`
|
||||
# - use `wayland` instead of `auto` because --ozone-platform-hint=auto still prefers X over wayland when both are available
|
||||
# alternatively, set env var: `ELECTRON_OZONE_PLATFORM_HINT=wayland` and ignore all of this
|
||||
installPhase = lib.replaceStrings
|
||||
[ "NIXOS_OZONE_WL" "--ozone-platform-hint=auto" ]
|
||||
[ "WAYLAND_DISPLAY" "--ozone-platform-hint=wayland" ]
|
||||
upstream.installPhase
|
||||
;
|
||||
});
|
||||
|
||||
# sandbox.whitelistDbus.user = true;
|
||||
sandbox.net = "clearnet";
|
||||
sandbox.whitelistAudio = true; #< for calls, media
|
||||
|
Reference in New Issue
Block a user