From 9b0ed58123fd6d4a844537aa7a18db53015848ed Mon Sep 17 00:00:00 2001 From: "RingOfStorms (Joshua Bell)" Date: Fri, 18 Oct 2024 17:04:22 -0500 Subject: [PATCH] use wofi for wanland --- hosts/lio/configuration.nix | 1 + users/josh/home_manager/de/gnome.nix | 8 +++++++- users/josh/home_manager/launcher_rofi.nix | 12 ++++++++++-- 3 files changed, 18 insertions(+), 3 deletions(-) diff --git a/hosts/lio/configuration.nix b/hosts/lio/configuration.nix index e3dd2a4..a4d0a8a 100644 --- a/hosts/lio/configuration.nix +++ b/hosts/lio/configuration.nix @@ -15,6 +15,7 @@ shell_common.enable = true; # de_cosmic.enable = true; de_gnome_xorg.enable = true; + # de_gnome_wayland.enable = true; audio_pulse.enable = true; neovim.enable = true; tty_caps_esc.enable = true; diff --git a/users/josh/home_manager/de/gnome.nix b/users/josh/home_manager/de/gnome.nix index 59a5d00..0d0907b 100644 --- a/users/josh/home_manager/de/gnome.nix +++ b/users/josh/home_manager/de/gnome.nix @@ -61,7 +61,13 @@ with lib.hm.gvariant; }; "org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1" = { binding = "Space"; - command = "rofi -show"; + command = + if nixConfig.mods.de_gnome_xorg.enable then + "rofi -show" + else if nixConfig.mods.de_gnome_wayland.enable then + "wofi --show drun" + else + ""; # fallback in case neither is enabled name = "Launcher"; }; "org/gnome/desktop/wm/keybindings" = { diff --git a/users/josh/home_manager/launcher_rofi.nix b/users/josh/home_manager/launcher_rofi.nix index 90456e6..2169e60 100644 --- a/users/josh/home_manager/launcher_rofi.nix +++ b/users/josh/home_manager/launcher_rofi.nix @@ -1,6 +1,11 @@ -{ pkgs, ... }: { - programs.rofi = { + pkgs, + nixConfig, + lib, + ... +}: +{ + programs.rofi = lib.mkIf nixConfig.mods.de_gnome_xorg.enable { enable = true; plugins = with pkgs; [ rofi-calc ]; extraConfig = { @@ -9,4 +14,7 @@ }; theme = "glue_pro_blue"; }; + programs.wofi = lib.mkIf nixConfig.mods.de_gnome_wayland.enable { + enable = true; + }; }