refactor: make wofi a module

This commit is contained in:
matt1432 2023-10-18 12:18:17 -04:00
parent f037501700
commit a1a98d9144
6 changed files with 25 additions and 23 deletions

View file

@ -73,7 +73,7 @@
imports = [ imports = [
../../modules/alacritty.nix ../../modules/alacritty.nix
../../modules/dconf.nix ../../modules/dconf.nix
../../modules/firefox/main.nix ../../modules/firefox
]; ];
programs.alacritty.settings.font.size = 10; programs.alacritty.settings.font.size = 10;

View file

@ -16,12 +16,13 @@
imports = [ imports = [
./theme.nix ./theme.nix
./hyprland.nix ./hyprland.nix
./dotfiles.nix ../modules/dotfiles.nix
./packages.nix ./packages.nix
../../../modules/alacritty.nix ../../../modules/alacritty.nix
../../../modules/dconf.nix ../../../modules/dconf.nix
../../../modules/firefox/main.nix ../../../modules/firefox
../../../modules/wofi
]; ];
home.stateVersion = "23.05"; home.stateVersion = "23.05";

View file

@ -1,6 +1,4 @@
{ config, pkgs, nixpkgs-wayland, ... }: let { config, pkgs, ... }: let
waypkgs = nixpkgs-wayland.packages.x86_64-linux;
configDir = (import ../vars.nix).configDir; configDir = (import ../vars.nix).configDir;
symlink = config.lib.file.mkOutOfStoreSymlink; symlink = config.lib.file.mkOutOfStoreSymlink;
in in
@ -26,21 +24,4 @@ in
"neofetch".source = symlink "${configDir}/neofetch"; "neofetch".source = symlink "${configDir}/neofetch";
"swappy".source = symlink "${configDir}/swappy"; "swappy".source = symlink "${configDir}/swappy";
}; };
programs = {
wofi = {
enable = true;
package = waypkgs.wofi;
settings = {
prompt = "";
allow_images = true;
normal_window = true;
image_size = "48";
matching = "fuzzy";
insensitive = true;
no_actions = true;
};
style = builtins.readFile ../config/wofi/style.css;
};
};
} }

20
modules/wofi/default.nix Normal file
View file

@ -0,0 +1,20 @@
# Home-manager module
{ nixpkgs-wayland, ... }: {
programs = {
wofi = {
enable = true;
package = nixpkgs-wayland.packages.x86_64-linux.wofi;
settings = {
prompt = "";
allow_images = true;
normal_window = true;
image_size = "48";
matching = "fuzzy";
insensitive = true;
no_actions = true;
};
style = builtins.readFile ./style.css;
};
};
}