improve hyprland module portability

This commit is contained in:
Noa Aarts 2024-05-29 12:41:44 +02:00
parent 666e0a8bc6
commit b0d1785ce9
3 changed files with 15 additions and 17 deletions

View file

@ -48,7 +48,7 @@
}; };
outputs = { self, nixpkgs, nix-colors, automapaper, disko, home-manager, hyprland, lazy, ... }@inputs: outputs = { self, nixpkgs, nix-colors, automapaper, disko, hyprland, lazy, ... }@inputs:
{ {
nixosConfigurations = { nixosConfigurations = {
lambdaOS = nixpkgs.lib.nixosSystem { lambdaOS = nixpkgs.lib.nixosSystem {

View file

@ -7,7 +7,6 @@
imports = imports =
[ # Include the results of the hardware scan. [ # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
inputs.home-manager.nixosModules.default
../../modules/games/steam.nix ../../modules/games/steam.nix
inputs.nix-minecraft.nixosModules.minecraft-servers inputs.nix-minecraft.nixosModules.minecraft-servers
]; ];
@ -128,7 +127,7 @@
mangohud mangohud
]; ];
# TODO find list of fonts to install # TODO: find list of fonts to install
fonts.packages = with pkgs; [ fonts.packages = with pkgs; [
font-awesome font-awesome
noto-fonts noto-fonts

View file

@ -50,7 +50,6 @@ in
wl-clipboard wl-clipboard
inputs.hyprpicker inputs.hyprpicker
hyprshot
hypridle # TODO: remove when fixed with config hypridle # TODO: remove when fixed with config
playerctl playerctl
@ -77,11 +76,11 @@ in
"WLR_NO_HARDWARE_CURSORS,1" "WLR_NO_HARDWARE_CURSORS,1"
]; ];
exec-once = [ exec-once = [
"waybar" "${pkgs.waybar}/bin/waybar"
"dunst" "${pkgs.dunst}/bin/dunst"
(lib.mkIf config.modules.automapaper.enable "automapaper -C ${config.xdg.configHome}/automapaper/config.toml") (lib.mkIf config.modules.automapaper.enable "${inputs.automapaper}/bin/automapaper -C ${config.xdg.configHome}/automapaper/config.toml")
(lib.mkIf config.modules.automapaper.enable "automapaper -C ${config.xdg.configHome}/automapaper/config2nd.toml") (lib.mkIf config.modules.automapaper.enable "${inputs.automapaper}/bin/automapaper -C ${config.xdg.configHome}/automapaper/config2nd.toml")
"hyprctl dispatcher focusmonitor 1" "${cfg.package}/bin/hyprctl dispatcher focusmonitor 1"
"hypridle" "hypridle"
]; ];
general = { general = {
@ -115,7 +114,7 @@ in
}; };
"$mod" = "SUPER"; "$mod" = "SUPER";
bind = [ bind = [
"$mod,Return,exec,${cfg.terminal.pname}" "$mod,Return,exec,${cfg.terminal}/bin/${cfg.terminal.pname}"
"$mod,tab,cyclenext" "$mod,tab,cyclenext"
"SUPERSHIFT,Q,killactive" "SUPERSHIFT,Q,killactive"
"$mod,SPACE,exec,wofi-launch" "$mod,SPACE,exec,wofi-launch"
@ -132,14 +131,14 @@ in
"$mod,F,togglefloating" "$mod,F,togglefloating"
"$mod,X,togglespecialworkspace" "$mod,X,togglespecialworkspace"
"SUPERSHIFT,X,movetoworkspace,special" "SUPERSHIFT,X,movetoworkspace,special"
"SUPERSHIFT,S,exec,hyprshot -m region --clipboard-only" "SUPERSHIFT,S,exec,${pkgs.hyprshot}/bin/hyprshot -m region --clipboard-only"
"$mod,f11,fullscreen,0" "$mod,f11,fullscreen,0"
",XF86AudioLowerVolume,exec,wpctl set-volume @DEFAULT_SINK@ 1%-" ",XF86AudioLowerVolume,exec,${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_SINK@ 1%-"
",XF86AudioRaiseVolume,exec,wpctl set-volume @DEFAULT_SINK@ 1%+" ",XF86AudioRaiseVolume,exec,${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_SINK@ 1%+"
",XF86AudioMute,exec,wpctl set-mute @DEFAULT_SINK@ toggle" ",XF86AudioMute,exec,${pkgs.wireplumber}/bin/wpctl set-mute @DEFAULT_SINK@ toggle"
",XF86AudioPlay,exec,playerctl play-pause" ",XF86AudioPlay,exec,${pkgs.playerctl}/bin/playerctl play-pause"
",XF86AudioPrev,exec,playerctl previous" ",XF86AudioPrev,exec,${pkgs.playerctl}/bin/playerctl previous"
",XF86AudioNext,exec,playerctl next" ",XF86AudioNext,exec,${pkgs.playerctl}/bin/playerctl next"
] ]
++ ( ++ (
builtins.concatLists (builtins.genList ( builtins.concatLists (builtins.genList (