From d63587f8e18a4be783d181f06f7af3f728bbc95e Mon Sep 17 00:00:00 2001 From: Krzysztof Saczuk Date: Mon, 2 Dec 2024 12:38:15 +0100 Subject: [PATCH] refactor(apps): switch discord client to `canary` branch instead of `vesktop` --- modules/desktop/apps/discord.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/modules/desktop/apps/discord.nix b/modules/desktop/apps/discord.nix index 853c863..613eb55 100644 --- a/modules/desktop/apps/discord.nix +++ b/modules/desktop/apps/discord.nix @@ -5,11 +5,12 @@ username, desktop, ... -}: -with lib; -with lib.my; -with lib.my.utils; let - pkg = pkgs.vesktop; +}: let + inherit (lib) getExe mkIf; + inherit (lib.my.utils) findLayoutConfig findLayoutWorkspace; + pkg = pkgs.discord-canary.override { + withOpenASAR = true; + }; leftLayout = findLayoutConfig config ({name, ...}: name == "left"); # Try and find left monitor # Left monitor or main if not found layout = @@ -21,10 +22,10 @@ with lib.my.utils; let if leftLayout != null then findLayoutWorkspace layout ({default, ...}: default) else findLayoutWorkspace layout ({last, ...}: last); - class = "^(vesktop)$"; + class = "^(discord)$"; in { modules.desktop.wm.${desktop}.autostartPrograms = [ - "${pkg}/bin/vesktop" + "${getExe pkg}" ]; home-manager.users.${username} = {