From 82a11ef821d146fbd819c28777102c13aabf09cf Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 24 Dec 2025 17:57:24 +0100 Subject: [PATCH 01/16] add conversion functions to catppuccin module --- dots/.config/fuzzel/fuzzel.ini.nix | 34 ++ dots/.config/kitty/kitty.conf.nix | 76 +-- dots/.config/waybar/style.css.nix | 32 +- dots/.config/wofi/style.css.nix | 36 +- flake.nix | 4 +- machines/terra/configuration.nix | 2 + modules/catppuccin/default.nix | 846 ++++++++++++++++++----------- modules/wm/hyprland/default.nix | 9 +- overlays/catppuccin.nix | 8 + overlays/default.nix | 7 + 10 files changed, 663 insertions(+), 391 deletions(-) create mode 100644 dots/.config/fuzzel/fuzzel.ini.nix create mode 100644 overlays/catppuccin.nix create mode 100644 overlays/default.nix diff --git a/dots/.config/fuzzel/fuzzel.ini.nix b/dots/.config/fuzzel/fuzzel.ini.nix new file mode 100644 index 0000000..37e1563 --- /dev/null +++ b/dots/.config/fuzzel/fuzzel.ini.nix @@ -0,0 +1,34 @@ +{ + lib, + config, + ... +}: let + inherit (lib) mkIf mkEnableOption catppuccin; + cfg = config.horseman.dots.fuzzel; + username = config.horseman.username; + colors = config.horseman.catppuccin.colors; + accent = config.horseman.catppuccin.accent; +in { + options = { + horseman.dots.fuzzel = { + enable = mkEnableOption "~/.config/fuzzel/fuzzel.ini"; + }; + }; + + config = mkIf cfg.enable { + home-manager.users.${username}.xdg.configFile."fuzzel/fuzzel.ini".text = '' + [colors] + background=${catppuccin.toHexNoHash colors.base}dd + text=${catppuccin.toHexNoHash colors.text}ff + prompt=${catppuccin.toHexNoHash colors.subtext1}ff + placeholder=${catppuccin.toHexNoHash colors.overlay1}ff + input=${catppuccin.toHexNoHash colors.text}ff + match=${catppuccin.toHexNoHash colors.${accent}}ff + selection=${catppuccin.toHexNoHash colors.surface2}ff + selection-text=${catppuccin.toHexNoHash colors.text}ff + selection-match=${catppuccin.toHexNoHash colors.${accent}}ff + counter=${catppuccin.toHexNoHash colors.overlay1}ff + border=${catppuccin.toHexNoHash colors.${accent}}ff + ''; + }; +} diff --git a/dots/.config/kitty/kitty.conf.nix b/dots/.config/kitty/kitty.conf.nix index c59f1df..72e182e 100644 --- a/dots/.config/kitty/kitty.conf.nix +++ b/dots/.config/kitty/kitty.conf.nix @@ -3,7 +3,7 @@ config, ... }: let - inherit (lib) mkIf mkEnableOption mkOption types; + inherit (lib) mkIf mkEnableOption mkOption types catppuccin; cfg = config.horseman.dots.kitty; username = config.horseman.username; colors = config.horseman.catppuccin.colors; @@ -33,75 +33,75 @@ in { font_size ${toString cfg.fontSize} # The basic colors - foreground ${colors.text} - background ${colors.base} - selection_foreground ${colors.base} - selection_background ${colors.rosewater} + foreground ${catppuccin.toHex colors.text} + background ${catppuccin.toHex colors.base} + selection_foreground ${catppuccin.toHex colors.base} + selection_background ${catppuccin.toHex colors.rosewater} # Cursor colors - cursor ${colors.rosewater} - cursor_text_color ${colors.base} + cursor ${catppuccin.toHex colors.rosewater} + cursor_text_color ${catppuccin.toHex colors.base} # URL underline color when hovering with mouse - url_color ${colors.rosewater} + url_color ${catppuccin.toHex colors.rosewater} # Kitty window border colors - active_border_color ${colors.lavender} - inactive_border_color ${colors.overlay0} - bell_border_color ${colors.yellow} + active_border_color ${catppuccin.toHex colors.lavender} + inactive_border_color ${catppuccin.toHex colors.overlay0} + bell_border_color ${catppuccin.toHex colors.yellow} # OS Window titlebar colors wayland_titlebar_color system macos_titlebar_color system # Tab bar colors - active_tab_foreground ${colors.crust} - active_tab_background ${colors.mauve} - inactive_tab_foreground ${colors.text} - inactive_tab_background ${colors.mantle} - tab_bar_background ${colors.crust} + active_tab_foreground ${catppuccin.toHex colors.crust} + active_tab_background ${catppuccin.toHex colors.mauve} + inactive_tab_foreground ${catppuccin.toHex colors.text} + inactive_tab_background ${catppuccin.toHex colors.mantle} + tab_bar_background ${catppuccin.toHex colors.crust} # Colors for marks (marked text in the terminal) - mark1_foreground ${colors.base} - mark1_background ${colors.lavender} - mark2_foreground ${colors.base} - mark2_background ${colors.mauve} - mark3_foreground ${colors.base} - mark3_background ${colors.sapphire} + mark1_foreground ${catppuccin.toHex colors.base} + mark1_background ${catppuccin.toHex colors.lavender} + mark2_foreground ${catppuccin.toHex colors.base} + mark2_background ${catppuccin.toHex colors.mauve} + mark3_foreground ${catppuccin.toHex colors.base} + mark3_background ${catppuccin.toHex colors.sapphire} # The 16 terminal colors # black - color0 ${colors.surface1} - color8 ${colors.surface2} + color0 ${catppuccin.toHex colors.surface1} + color8 ${catppuccin.toHex colors.surface2} # red - color1 ${colors.red} - color9 ${colors.red} + color1 ${catppuccin.toHex colors.red} + color9 ${catppuccin.toHex colors.red} # green - color2 ${colors.green} - color10 ${colors.green} + color2 ${catppuccin.toHex colors.green} + color10 ${catppuccin.toHex colors.green} # yellow - color3 ${colors.yellow} - color11 ${colors.yellow} + color3 ${catppuccin.toHex colors.yellow} + color11 ${catppuccin.toHex colors.yellow} # blue - color4 ${colors.blue} - color12 ${colors.blue} + color4 ${catppuccin.toHex colors.blue} + color12 ${catppuccin.toHex colors.blue} # magenta - color5 ${colors.mauve} - color13 ${colors.mauve} + color5 ${catppuccin.toHex colors.mauve} + color13 ${catppuccin.toHex colors.mauve} # cyan - color6 ${colors.teal} - color14 ${colors.teal} + color6 ${catppuccin.toHex colors.teal} + color14 ${catppuccin.toHex colors.teal} # white - color7 ${colors.subtext1} - color15 ${colors.subtext0} + color7 ${catppuccin.toHex colors.subtext1} + color15 ${catppuccin.toHex colors.subtext0} ''; }; } diff --git a/dots/.config/waybar/style.css.nix b/dots/.config/waybar/style.css.nix index be75ea0..c2c7d82 100644 --- a/dots/.config/waybar/style.css.nix +++ b/dots/.config/waybar/style.css.nix @@ -3,7 +3,7 @@ config, ... }: let - inherit (lib) mkIf mkEnableOption; + inherit (lib) mkIf mkEnableOption catppuccin; cfg = config.horseman.dots.waybar; username = config.horseman.username; colors = config.horseman.catppuccin.colors; @@ -26,33 +26,33 @@ in { } .modules-left, .modules-center, .modules-right { - border: 2px solid ${colors.${accent}}; + border: 2px solid ${catppuccin.toHex colors.${accent}}; border-radius: 10px; margin: 5px; - background: ${colors.base}; - color: ${colors.text}; + background: ${catppuccin.toHex colors.base}; + color: ${catppuccin.toHex colors.text}; } #power { padding-left: 10px; } #idle_inhibitor.activated { - color: ${colors.red}; + color: ${catppuccin.toHex colors.red}; } #power * { - color: ${colors.${accent}}; + color: ${catppuccin.toHex colors.${accent}}; transition: 0.2s color ease; font-size: 26px; } #power *:hover { - color: ${colors.red}; + color: ${catppuccin.toHex colors.red}; } #workspaces .empty { - color: ${colors.surface0}; + color: ${catppuccin.toHex colors.surface0}; } #workspaces .active { - color: ${colors.red}; + color: ${catppuccin.toHex colors.red}; font-size: 18px; } #workspaces * { @@ -62,27 +62,27 @@ in { } #workspaces > * { - color: ${colors.${accent}}; + color: ${catppuccin.toHex colors.${accent}}; } #clock { - color: ${colors.peach}; + color: ${catppuccin.toHex colors.peach}; } #battery { - color: ${colors.maroon}; + color: ${catppuccin.toHex colors.maroon}; } #cpu { - color: ${colors.red}; + color: ${catppuccin.toHex colors.red}; } #memory { - color: ${colors.mauve}; + color: ${catppuccin.toHex colors.mauve}; } #pulseaudio { - color: ${colors.blue}; + color: ${catppuccin.toHex colors.blue}; } #network { - color: ${colors.teal}; + color: ${catppuccin.toHex colors.teal}; } .horizontal .modules-right { font-size: 16px; diff --git a/dots/.config/wofi/style.css.nix b/dots/.config/wofi/style.css.nix index b47e2dd..f010423 100644 --- a/dots/.config/wofi/style.css.nix +++ b/dots/.config/wofi/style.css.nix @@ -3,7 +3,7 @@ config, ... }: let - inherit (lib) mkIf mkEnableOption; + inherit (lib) mkIf mkEnableOption catppuccin; cfg = config.horseman.dots.wofi; username = config.horseman.username; colors = config.horseman.catppuccin.colors; @@ -26,9 +26,9 @@ in { window { margin: 0px; padding: 10px; - border: 3px solid ${colors.${accent}}; + border: 3px solid ${catppuccin.toHex colors.${accent}}; border-radius: 10px; - background-color: ${builtins.replaceStrings ["rgb" ")"] ["rgba" ", 0.99)"] colors.base-rgb}; + background-color: ${catppuccin.toRGBA colors.base 0.99}; /* animation: slideIn 0.5s ease-in-out both; */ } @@ -48,7 +48,7 @@ in { margin: 5px; padding: 10px; border: none; - background-color: ${colors.base}; + background-color: ${catppuccin.toHex colors.base}; /* animation: fadeIn 0.5s ease-in-out both; */ } @@ -68,7 +68,7 @@ in { margin: 5px; padding: 10px; border: none; - background-color: ${colors.base}; + background-color: ${catppuccin.toHex colors.base}; } /* Scroll */ @@ -76,63 +76,63 @@ in { margin: 0px; padding: 10px; border: none; - background-color: ${colors.base}; + background-color: ${catppuccin.toHex colors.base}; } /* Input */ #input { margin: 5px 20px; padding: 10px; - border: 2px solid ${colors.${accent}}; + border: 2px solid ${catppuccin.toHex colors.${accent}}; border-radius: 10px; - color: ${colors.text}; - background-color: ${colors.base}; + color: ${catppuccin.toHex colors.text}; + background-color: ${catppuccin.toHex colors.base}; /* animation: fadeIn 0.5s ease-in-out both; */ } #input image { border: none; - color: ${colors.red}; + color: ${catppuccin.toHex colors.red}; } #input * { - outline: 4px solid ${colors.red}!important; + outline: 4px solid ${catppuccin.toHex colors.red}!important; } /* Text */ #text { margin: 5px; border: none; - color: ${colors.text}; + color: ${catppuccin.toHex colors.text}; /* animation: fadeIn 0.5s ease-in-out both; */ } #entry { - background-color: ${colors.base}; + background-color: ${catppuccin.toHex colors.base}; } #entry arrow { border: none; - color: ${colors.${accent}}; + color: ${catppuccin.toHex colors.${accent}}; } /* Selected Entry */ #entry:selected arrow { overflow: hidden; - color: ${colors.mauve}; + color: ${catppuccin.toHex colors.mauve}; } #entry:selected { - border: 1px solid ${colors.${accent}}; + border: 1px solid ${catppuccin.toHex colors.${accent}}; border-radius: 10px; } #entry:selected #text { - color: ${colors.mauve}; + color: ${catppuccin.toHex colors.mauve}; } #entry:drop(active) { - background-color: ${colors.${accent}}!important; + background-color: ${catppuccin.toHex colors.${accent}}!important; } ''; }; diff --git a/flake.nix b/flake.nix index e2dcfa1..aa12078 100644 --- a/flake.nix +++ b/flake.nix @@ -46,13 +46,15 @@ "x86_64-darwin" ]; forAllSystems = nixpkgs.lib.genAttrs systems; + + lib = import ./overlays {inherit inputs;}; in { formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra); nixosConfigurations = nixpkgs.lib.genAttrs hosts (host: nixpkgs.lib.nixosSystem { specialArgs = { - inherit inputs outputs; + inherit inputs outputs lib; }; modules = [ ./lib diff --git a/machines/terra/configuration.nix b/machines/terra/configuration.nix index a5a9957..4ddf472 100644 --- a/machines/terra/configuration.nix +++ b/machines/terra/configuration.nix @@ -8,4 +8,6 @@ horseman.stateVersion = "24.11"; networking.hostName = "terra"; + + programs.niri.enable = true; } diff --git a/modules/catppuccin/default.nix b/modules/catppuccin/default.nix index 05d2633..e6adb02 100644 --- a/modules/catppuccin/default.nix +++ b/modules/catppuccin/default.nix @@ -9,324 +9,532 @@ flavors = { mocha = { - rosewater = "#f5e0dc"; - rosewater-rgb = "rgb(245, 224, 220)"; - rosewater-hsl = "hsl(10, 56%, 91%)"; - flamingo = "#f2cdcd"; - flamingo-rgb = "rgb(242, 205, 205)"; - flamingo-hsl = "hsl(0, 59%, 88%)"; - pink = "#f5c2e7"; - pink-rgb = "rgb(245, 194, 231)"; - pink-hsl = "hsl(316, 72%, 86%)"; - mauve = "#cba6f7"; - mauve-rgb = "rgb(203, 166, 247)"; - mauve-hsl = "hsl(267, 84%, 81%)"; - red = "#f38ba8"; - red-rgb = "rgb(243, 139, 168)"; - red-hsl = "hsl(343, 81%, 75%)"; - maroon = "#eba0ac"; - maroon-rgb = "rgb(235, 160, 172)"; - maroon-hsl = "hsl(350, 65%, 77%)"; - peach = "#fab387"; - peach-rgb = "rgb(250, 179, 135)"; - peach-hsl = "hsl(23, 92%, 75%)"; - yellow = "#f9e2af"; - yellow-rgb = "rgb(249, 226, 175)"; - yellow-hsl = "hsl(41, 86%, 83%)"; - green = "#a6e3a1"; - green-rgb = "rgb(166, 227, 161)"; - green-hsl = "hsl(115, 54%, 76%)"; - teal = "#94e2d5"; - teal-rgb = "rgb(148, 226, 213)"; - teal-hsl = "hsl(170, 57%, 73%)"; - sky = "#89dceb"; - sky-rgb = "rgb(137, 220, 235)"; - sky-hsl = "hsl(189, 71%, 73%)"; - sapphire = "#74c7ec"; - sapphire-rgb = "rgb(116, 199, 236)"; - sapphire-hsl = "hsl(199, 76%, 69%)"; - blue = "#89b4fa"; - blue-rgb = "rgb(137, 180, 250)"; - blue-hsl = "hsl(217, 92%, 76%)"; - lavender = "#b4befe"; - lavender-rgb = "rgb(180, 190, 254)"; - lavender-hsl = "hsl(232, 97%, 85%)"; - text = "#cdd6f4"; - text-rgb = "rgb(205, 214, 244)"; - text-hsl = "hsl(226, 64%, 88%)"; - subtext1 = "#bac2de"; - subtext1-rgb = "rgb(186, 194, 222)"; - subtext1-hsl = "hsl(227, 35%, 80%)"; - subtext0 = "#a6adc8"; - subtext0-rgb = "rgb(166, 173, 200)"; - subtext0-hsl = "hsl(228, 24%, 72%)"; - overlay2 = "#9399b2"; - overlay2-rgb = "rgb(147, 153, 178)"; - overlay2-hsl = "hsl(228, 17%, 64%)"; - overlay1 = "#7f849c"; - overlay1-rgb = "rgb(127, 132, 156)"; - overlay1-hsl = "hsl(230, 13%, 55%)"; - overlay0 = "#6c7086"; - overlay0-rgb = "rgb(108, 112, 134)"; - overlay0-hsl = "hsl(231, 11%, 47%)"; - surface2 = "#585b70"; - surface2-rgb = "rgb(88, 91, 112)"; - surface2-hsl = "hsl(233, 12%, 39%)"; - surface1 = "#45475a"; - surface1-rgb = "rgb(69, 71, 90)"; - surface1-hsl = "hsl(234, 13%, 31%)"; - surface0 = "#313244"; - surface0-rgb = "rgb(49, 50, 68)"; - surface0-hsl = "hsl(237, 16%, 23%)"; - base = "#1e1e2e"; - base-rgb = "rgb(30, 30, 46)"; - base-hsl = "hsl(240, 21%, 15%)"; - mantle = "#181825"; - mantle-rgb = "rgb(24, 24, 37)"; - mantle-hsl = "hsl(240, 21%, 12%)"; - crust = "#11111b"; - crust-rgb = "rgb(17, 17, 27)"; - crust-hsl = "hsl(240, 23%, 9%)"; + rosewater = { + red = 245; + green = 224; + blue = 220; + }; + flamingo = { + red = 242; + green = 205; + blue = 205; + }; + pink = { + red = 245; + green = 194; + blue = 231; + }; + mauve = { + red = 203; + green = 166; + blue = 247; + }; + red = { + red = 243; + green = 139; + blue = 168; + }; + maroon = { + red = 235; + green = 160; + blue = 172; + }; + peach = { + red = 250; + green = 179; + blue = 135; + }; + yellow = { + red = 249; + green = 226; + blue = 175; + }; + green = { + red = 166; + green = 227; + blue = 161; + }; + teal = { + red = 148; + green = 226; + blue = 213; + }; + sky = { + red = 137; + green = 220; + blue = 235; + }; + sapphire = { + red = 116; + green = 199; + blue = 236; + }; + blue = { + red = 137; + green = 180; + blue = 250; + }; + lavender = { + red = 180; + green = 190; + blue = 254; + }; + text = { + red = 205; + green = 214; + blue = 244; + }; + subtext1 = { + red = 186; + green = 194; + blue = 222; + }; + subtext0 = { + red = 166; + green = 173; + blue = 200; + }; + overlay2 = { + red = 147; + green = 153; + blue = 178; + }; + overlay1 = { + red = 127; + green = 132; + blue = 156; + }; + overlay0 = { + red = 108; + green = 112; + blue = 134; + }; + surface2 = { + red = 88; + green = 91; + blue = 112; + }; + surface1 = { + red = 69; + green = 71; + blue = 90; + }; + surface0 = { + red = 49; + green = 50; + blue = 68; + }; + base = { + red = 30; + green = 30; + blue = 46; + }; + mantle = { + red = 24; + green = 24; + blue = 37; + }; + crust = { + red = 17; + green = 17; + blue = 27; + }; }; macchiato = { - rosewater = "#f4dbd6"; - rosewater-rgb = "rgb(244, 219, 214)"; - rosewater-hsl = "hsl(10, 58%, 90%)"; - flamingo = "#f0c6c6"; - flamingo-rgb = "rgb(240, 198, 198)"; - flamingo-hsl = "hsl(0, 58%, 86%)"; - pink = "#f5bde6"; - pink-rgb = "rgb(245, 189, 230)"; - pink-hsl = "hsl(316, 74%, 85%)"; - mauve = "#c6a0f6"; - mauve-rgb = "rgb(198, 160, 246)"; - mauve-hsl = "hsl(267, 83%, 80%)"; - red = "#ed8796"; - red-rgb = "rgb(237, 135, 150)"; - red-hsl = "hsl(351, 74%, 73%)"; - maroon = "#ee99a0"; - maroon-rgb = "rgb(238, 153, 160)"; - maroon-hsl = "hsl(355, 71%, 77%)"; - peach = "#f5a97f"; - peach-rgb = "rgb(245, 169, 127)"; - peach-hsl = "hsl(21, 86%, 73%)"; - yellow = "#eed49f"; - yellow-rgb = "rgb(238, 212, 159)"; - yellow-hsl = "hsl(40, 70%, 78%)"; - green = "#a6da95"; - green-rgb = "rgb(166, 218, 149)"; - green-hsl = "hsl(105, 48%, 72%)"; - teal = "#8bd5ca"; - teal-rgb = "rgb(139, 213, 202)"; - teal-hsl = "hsl(171, 47%, 69%)"; - sky = "#91d7e3"; - sky-rgb = "rgb(145, 215, 227)"; - sky-hsl = "hsl(189, 59%, 73%)"; - sapphire = "#7dc4e4"; - sapphire-rgb = "rgb(125, 196, 228)"; - sapphire-hsl = "hsl(199, 66%, 69%)"; - blue = "#8aadf4"; - blue-rgb = "rgb(138, 173, 244)"; - blue-hsl = "hsl(220, 83%, 75%)"; - lavender = "#b7bdf8"; - lavender-rgb = "rgb(183, 189, 248)"; - lavender-hsl = "hsl(234, 82%, 85%)"; - text = "#cad3f5"; - text-rgb = "rgb(202, 211, 245)"; - text-hsl = "hsl(227, 68%, 88%)"; - subtext1 = "#b8c0e0"; - subtext1-rgb = "rgb(184, 192, 224)"; - subtext1-hsl = "hsl(228, 39%, 80%)"; - subtext0 = "#a5adcb"; - subtext0-rgb = "rgb(165, 173, 203)"; - subtext0-hsl = "hsl(227, 27%, 72%)"; - overlay2 = "#939ab7"; - overlay2-rgb = "rgb(147, 154, 183)"; - overlay2-hsl = "hsl(228, 20%, 65%)"; - overlay1 = "#8087a2"; - overlay1-rgb = "rgb(128, 135, 162)"; - overlay1-hsl = "hsl(228, 15%, 57%)"; - overlay0 = "#6e738d"; - overlay0-rgb = "rgb(110, 115, 141)"; - overlay0-hsl = "hsl(230, 12%, 49%)"; - surface2 = "#5b6078"; - surface2-rgb = "rgb(91, 96, 120)"; - surface2-hsl = "hsl(230, 14%, 41%)"; - surface1 = "#494d64"; - surface1-rgb = "rgb(73, 77, 100)"; - surface1-hsl = "hsl(231, 16%, 34%)"; - surface0 = "#363a4f"; - surface0-rgb = "rgb(54, 58, 79)"; - surface0-hsl = "hsl(230, 19%, 26%)"; - base = "#24273a"; - base-rgb = "rgb(36, 39, 58)"; - base-hsl = "hsl(232, 23%, 18%)"; - mantle = "#1e2030"; - mantle-rgb = "rgb(30, 32, 48)"; - mantle-hsl = "hsl(233, 23%, 15%)"; - crust = "#181926"; - crust-rgb = "rgb(24, 25, 38)"; - crust-hsl = "hsl(236, 23%, 12%)"; + rosewater = { + red = 244; + green = 219; + blue = 214; + }; + flamingo = { + red = 240; + green = 198; + blue = 198; + }; + pink = { + red = 245; + green = 189; + blue = 230; + }; + mauve = { + red = 198; + green = 160; + blue = 246; + }; + red = { + red = 237; + green = 135; + blue = 150; + }; + maroon = { + red = 238; + green = 153; + blue = 160; + }; + peach = { + red = 245; + green = 169; + blue = 127; + }; + yellow = { + red = 238; + green = 212; + blue = 159; + }; + green = { + red = 166; + green = 218; + blue = 149; + }; + teal = { + red = 139; + green = 213; + blue = 202; + }; + sky = { + red = 145; + green = 215; + blue = 227; + }; + sapphire = { + red = 125; + green = 196; + blue = 228; + }; + blue = { + red = 138; + green = 173; + blue = 244; + }; + lavender = { + red = 183; + green = 189; + blue = 248; + }; + text = { + red = 202; + green = 211; + blue = 245; + }; + subtext1 = { + red = 184; + green = 192; + blue = 224; + }; + subtext0 = { + red = 165; + green = 173; + blue = 203; + }; + overlay2 = { + red = 147; + green = 154; + blue = 183; + }; + overlay1 = { + red = 128; + green = 135; + blue = 162; + }; + overlay0 = { + red = 110; + green = 115; + blue = 141; + }; + surface2 = { + red = 91; + green = 96; + blue = 120; + }; + surface1 = { + red = 73; + green = 77; + blue = 100; + }; + surface0 = { + red = 54; + green = 58; + blue = 79; + }; + base = { + red = 36; + green = 39; + blue = 58; + }; + mantle = { + red = 30; + green = 32; + blue = 48; + }; + crust = { + red = 24; + green = 25; + blue = 38; + }; }; frappe = { - rosewater = "#f2d5cf"; - rosewater-rgb = "rgb(242, 213, 207)"; - rosewater-hsl = "hsl(10, 57%, 88%)"; - flamingo = "#eebebe"; - flamingo-rgb = "rgb(238, 190, 190)"; - flamingo-hsl = "hsl(0, 59%, 84%)"; - pink = "#f4b8e4"; - pink-rgb = "rgb(244, 184, 228)"; - pink-hsl = "hsl(316, 73%, 84%)"; - mauve = "#ca9ee6"; - mauve-rgb = "rgb(202, 158, 230)"; - mauve-hsl = "hsl(277, 59%, 76%)"; - red = "#e78284"; - red-rgb = "rgb(231, 130, 132)"; - red-hsl = "hsl(359, 68%, 71%)"; - maroon = "#ea999c"; - maroon-rgb = "rgb(234, 153, 156)"; - maroon-hsl = "hsl(358, 66%, 76%)"; - peach = "#ef9f76"; - peach-rgb = "rgb(239, 159, 118)"; - peach-hsl = "hsl(20, 79%, 70%)"; - yellow = "#e5c890"; - yellow-rgb = "rgb(229, 200, 144)"; - yellow-hsl = "hsl(40, 62%, 73%)"; - green = "#a6d189"; - green-rgb = "rgb(166, 209, 137)"; - green-hsl = "hsl(96, 44%, 68%)"; - teal = "#81c8be"; - teal-rgb = "rgb(129, 200, 190)"; - teal-hsl = "hsl(172, 39%, 65%)"; - sky = "#99d1db"; - sky-rgb = "rgb(153, 209, 219)"; - sky-hsl = "hsl(189, 48%, 73%)"; - sapphire = "#85c1dc"; - sapphire-rgb = "rgb(133, 193, 220)"; - sapphire-hsl = "hsl(199, 55%, 69%)"; - blue = "#8caaee"; - blue-rgb = "rgb(140, 170, 238)"; - blue-hsl = "hsl(222, 74%, 74%)"; - lavender = "#babbf1"; - lavender-rgb = "rgb(186, 187, 241)"; - lavender-hsl = "hsl(239, 66%, 84%)"; - text = "#c6d0f5"; - text-rgb = "rgb(198, 208, 245)"; - text-hsl = "hsl(227, 70%, 87%)"; - subtext1 = "#b5bfe2"; - subtext1-rgb = "rgb(181, 191, 226)"; - subtext1-hsl = "hsl(227, 44%, 80%)"; - subtext0 = "#a5adce"; - subtext0-rgb = "rgb(165, 173, 206)"; - subtext0-hsl = "hsl(228, 29%, 73%)"; - overlay2 = "#949cbb"; - overlay2-rgb = "rgb(148, 156, 187)"; - overlay2-hsl = "hsl(228, 22%, 66%)"; - overlay1 = "#838ba7"; - overlay1-rgb = "rgb(131, 139, 167)"; - overlay1-hsl = "hsl(227, 17%, 58%)"; - overlay0 = "#737994"; - overlay0-rgb = "rgb(115, 121, 148)"; - overlay0-hsl = "hsl(229, 13%, 52%)"; - surface2 = "#626880"; - surface2-rgb = "rgb(98, 104, 128)"; - surface2-hsl = "hsl(228, 13%, 44%)"; - surface1 = "#51576d"; - surface1-rgb = "rgb(81, 87, 109)"; - surface1-hsl = "hsl(227, 15%, 37%)"; - surface0 = "#414559"; - surface0-rgb = "rgb(65, 69, 89)"; - surface0-hsl = "hsl(230, 16%, 30%)"; - base = "#303446"; - base-rgb = "rgb(48, 52, 70)"; - base-hsl = "hsl(229, 19%, 23%)"; - mantle = "#292c3c"; - mantle-rgb = "rgb(41, 44, 60)"; - mantle-hsl = "hsl(231, 19%, 20%)"; - crust = "#232634"; - crust-rgb = "rgb(35, 38, 52)"; - crust-hsl = "hsl(229, 20%, 17%)"; + rosewater = { + red = 242; + green = 213; + blue = 207; + }; + flamingo = { + red = 238; + green = 190; + blue = 190; + }; + pink = { + red = 244; + green = 184; + blue = 228; + }; + mauve = { + red = 202; + green = 158; + blue = 230; + }; + red = { + red = 231; + green = 130; + blue = 132; + }; + maroon = { + red = 234; + green = 153; + blue = 156; + }; + peach = { + red = 239; + green = 159; + blue = 118; + }; + yellow = { + red = 229; + green = 200; + blue = 144; + }; + green = { + red = 166; + green = 209; + blue = 137; + }; + teal = { + red = 129; + green = 200; + blue = 190; + }; + sky = { + red = 153; + green = 209; + blue = 219; + }; + sapphire = { + red = 133; + green = 193; + blue = 220; + }; + blue = { + red = 140; + green = 170; + blue = 238; + }; + lavender = { + red = 186; + green = 187; + blue = 241; + }; + text = { + red = 198; + green = 208; + blue = 245; + }; + subtext1 = { + red = 181; + green = 191; + blue = 226; + }; + subtext0 = { + red = 165; + green = 173; + blue = 206; + }; + overlay2 = { + red = 148; + green = 156; + blue = 187; + }; + overlay1 = { + red = 131; + green = 139; + blue = 167; + }; + overlay0 = { + red = 115; + green = 121; + blue = 148; + }; + surface2 = { + red = 98; + green = 104; + blue = 128; + }; + surface1 = { + red = 81; + green = 87; + blue = 109; + }; + surface0 = { + red = 65; + green = 69; + blue = 89; + }; + base = { + red = 48; + green = 52; + blue = 70; + }; + mantle = { + red = 41; + green = 44; + blue = 60; + }; + crust = { + red = 35; + green = 38; + blue = 52; + }; }; latte = { - rosewater = "#dc8a78"; - rosewater-rgb = "rgb(220, 138, 120)"; - rosewater-hsl = "hsl(11, 59%, 67%)"; - flamingo = "#dd7878"; - flamingo-rgb = "rgb(221, 120, 120)"; - flamingo-hsl = "hsl(0, 60%, 67%)"; - pink = "#ea76cb"; - pink-rgb = "rgb(234, 118, 203)"; - pink-hsl = "hsl(316, 73%, 69%)"; - mauve = "#8839ef"; - mauve-rgb = "rgb(136, 57, 239)"; - mauve-hsl = "hsl(266, 85%, 58%)"; - red = "#d20f39"; - red-rgb = "rgb(210, 15, 57)"; - red-hsl = "hsl(347, 87%, 44%)"; - maroon = "#e64553"; - maroon-rgb = "rgb(230, 69, 83)"; - maroon-hsl = "hsl(355, 76%, 59%)"; - peach = "#fe640b"; - peach-rgb = "rgb(254, 100, 11)"; - peach-hsl = "hsl(22, 99%, 52%)"; - yellow = "#df8e1d"; - yellow-rgb = "rgb(223, 142, 29)"; - yellow-hsl = "hsl(35, 77%, 49%)"; - green = "#40a02b"; - green-rgb = "rgb(64, 160, 43)"; - green-hsl = "hsl(109, 58%, 40%)"; - teal = "#179299"; - teal-rgb = "rgb(23, 146, 153)"; - teal-hsl = "hsl(183, 74%, 35%)"; - sky = "#04a5e5"; - sky-rgb = "rgb(4, 165, 229)"; - sky-hsl = "hsl(197, 97%, 46%)"; - sapphire = "#209fb5"; - sapphire-rgb = "rgb(32, 159, 181)"; - sapphire-hsl = "hsl(189, 70%, 42%)"; - blue = "#1e66f5"; - blue-rgb = "rgb(30, 102, 245)"; - blue-hsl = "hsl(220, 91%, 54%)"; - lavender = "#7287fd"; - lavender-rgb = "rgb(114, 135, 253)"; - lavender-hsl = "hsl(231, 97%, 72%)"; - text = "#4c4f69"; - text-rgb = "rgb(76, 79, 105)"; - text-hsl = "hsl(234, 16%, 35%)"; - subtext1 = "#5c5f77"; - subtext1-rgb = "rgb(92, 95, 119)"; - subtext1-hsl = "hsl(233, 13%, 41%)"; - subtext0 = "#6c6f85"; - subtext0-rgb = "rgb(108, 111, 133)"; - subtext0-hsl = "hsl(233, 10%, 47%)"; - overlay2 = "#7c7f93"; - overlay2-rgb = "rgb(124, 127, 147)"; - overlay2-hsl = "hsl(232, 10%, 53%)"; - overlay1 = "#8c8fa1"; - overlay1-rgb = "rgb(140, 143, 161)"; - overlay1-hsl = "hsl(231, 10%, 59%)"; - overlay0 = "#9ca0b0"; - overlay0-rgb = "rgb(156, 160, 176)"; - overlay0-hsl = "hsl(228, 11%, 65%)"; - surface2 = "#acb0be"; - surface2-rgb = "rgb(172, 176, 190)"; - surface2-hsl = "hsl(227, 12%, 71%)"; - surface1 = "#bcc0cc"; - surface1-rgb = "rgb(188, 192, 204)"; - surface1-hsl = "hsl(225, 14%, 77%)"; - surface0 = "#ccd0da"; - surface0-rgb = "rgb(204, 208, 218)"; - surface0-hsl = "hsl(223, 16%, 83%)"; - base = "#eff1f5"; - base-rgb = "rgb(239, 241, 245)"; - base-hsl = "hsl(220, 23%, 95%)"; - mantle = "#e6e9ef"; - mantle-rgb = "rgb(230, 233, 239)"; - mantle-hsl = "hsl(220, 22%, 92%)"; - crust = "#dce0e8"; - crust-rgb = "rgb(220, 224, 232)"; - crust-hsl = "hsl(220, 21%, 89%)"; + rosewater = { + red = 220; + green = 138; + blue = 120; + }; + flamingo = { + red = 221; + green = 120; + blue = 120; + }; + pink = { + red = 234; + green = 118; + blue = 203; + }; + mauve = { + red = 136; + green = 57; + blue = 239; + }; + red = { + red = 210; + green = 15; + blue = 57; + }; + maroon = { + red = 230; + green = 69; + blue = 83; + }; + peach = { + red = 254; + green = 100; + blue = 11; + }; + yellow = { + red = 223; + green = 142; + blue = 29; + }; + green = { + red = 64; + green = 160; + blue = 43; + }; + teal = { + red = 23; + green = 146; + blue = 153; + }; + sky = { + red = 4; + green = 165; + blue = 229; + }; + sapphire = { + red = 32; + green = 159; + blue = 181; + }; + blue = { + red = 30; + green = 102; + blue = 245; + }; + lavender = { + red = 114; + green = 135; + blue = 253; + }; + text = { + red = 76; + green = 79; + blue = 105; + }; + subtext1 = { + red = 92; + green = 95; + blue = 119; + }; + subtext0 = { + red = 108; + green = 111; + blue = 133; + }; + overlay2 = { + red = 124; + green = 127; + blue = 147; + }; + overlay1 = { + red = 140; + green = 143; + blue = 161; + }; + overlay0 = { + red = 156; + green = 160; + blue = 176; + }; + surface2 = { + red = 172; + green = 176; + blue = 190; + }; + surface1 = { + red = 188; + green = 192; + blue = 204; + }; + surface0 = { + red = 204; + green = 208; + blue = 218; + }; + base = { + red = 239; + green = 241; + blue = 245; + }; + mantle = { + red = 230; + green = 233; + blue = 239; + }; + crust = { + red = 220; + green = 224; + blue = 232; + }; }; }; in { @@ -371,7 +579,19 @@ in { }; colors = mkOption { - type = types.attrsOf types.anything; + type = types.attrsOf (types.submodule { + options = { + red = mkOption { + type = types.int; + }; + green = mkOption { + type = types.int; + }; + blue = mkOption { + type = types.int; + }; + }; + }); readOnly = true; }; }; diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index 84fe07c..b8c5a7c 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -4,8 +4,7 @@ pkgs, ... }: let - inherit (lib) mkIf mkEnableOption; - inherit (builtins) replaceStrings; + inherit (lib) mkIf mkEnableOption catppuccin; cfg = config.horseman.wm.hyprland; colors = config.horseman.catppuccin.colors; @@ -40,7 +39,7 @@ in { playerctl # Media control pulsemixer # Audio frontend wl-clipboard # Clipboard - wofi # Launcher + fuzzel # Launcher xdg-desktop-portal-hyprland # XDG Portal (needed but idk why) ]; @@ -82,8 +81,8 @@ in { resizeOnBorder = true; allowTearing = false; - col.activeBorder = replaceStrings [" "] [""] colors."${accent}-rgb"; - col.inactiveBorder = replaceStrings [" " ")" "rgb"] ["" ",0.25)" "rgba"] colors."${accent}-rgb"; # Make transparent + col.activeBorder = catppuccin.toRGB colors.${accent}; + col.inactiveBorder = catppuccin.toRGBA colors.${accent} 0.25; layout = "dwindle"; }; diff --git a/overlays/catppuccin.nix b/overlays/catppuccin.nix new file mode 100644 index 0000000..5980626 --- /dev/null +++ b/overlays/catppuccin.nix @@ -0,0 +1,8 @@ +{inputs, ...}: let + inherit (inputs.nixpkgs.lib) toHexString concatStrings; +in { + toHex = color: concatStrings ["#" (toHexString color.red) (toHexString color.green) (toHexString color.blue)]; + toHexNoHash = color: concatStrings [(toHexString color.red) (toHexString color.green) (toHexString color.blue)]; + toRGB = color: concatStrings ["rgb(" (toString color.red) "," (toString color.green) "," (toString color.blue) ")"]; + toRGBA = color: a: concatStrings ["rgba(" (toString color.red) "," (toString color.green) "," (toString color.blue) "," (toString a) ")"]; +} diff --git a/overlays/default.nix b/overlays/default.nix new file mode 100644 index 0000000..17e93fa --- /dev/null +++ b/overlays/default.nix @@ -0,0 +1,7 @@ +# {inputs, ...}: import ./catppuccin.nix {inherit inputs;} +{inputs, ...}: +inputs.nixpkgs.lib.extend ( + final: prev: { + catppuccin = import ./catppuccin.nix {inherit inputs;}; + } +) From c158671e7096099143036758588c391978e4b0bf Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 24 Dec 2025 17:59:59 +0100 Subject: [PATCH 02/16] change launcher to fuzzel --- dots/default.nix | 1 + modules/wm/hyprland/keybindings.nix | 2 +- modules/wm/hyprland/options.nix | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/dots/default.nix b/dots/default.nix index ffa0c7c..5ee014b 100644 --- a/dots/default.nix +++ b/dots/default.nix @@ -2,6 +2,7 @@ imports = [ ./.warprc.nix ./.config/eza/theme.yml.nix + ./.config/fuzzel/fuzzel.ini.nix ./.config/hypr/hypridle.conf.nix ./.config/hypr/hyprlock.conf.nix ./.config/hypr/hyprland.conf.nix diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index 3f710cd..3615275 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -33,7 +33,7 @@ in { mods = ["SUPER"]; key = "SPACE"; dispatcher = "exec"; - params = "pkill wofi || wofi -i -S drun -M multi-contains"; + params = "pkill fuzzel || fuzzel -T kitty"; } { diff --git a/modules/wm/hyprland/options.nix b/modules/wm/hyprland/options.nix index d7a542a..0cc2b11 100644 --- a/modules/wm/hyprland/options.nix +++ b/modules/wm/hyprland/options.nix @@ -227,7 +227,7 @@ in { config = mkIf cfg.enable { horseman.dots = { - wofi.enable = true; + fuzzel.enable = true; waybar.enable = true; hypr = { hyprland.enable = true; From 418be1ed632ab4f63a39a5c7d0cbe271dece789b Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 24 Dec 2025 18:08:58 +0100 Subject: [PATCH 03/16] fix: leftPad to hex --- overlays/catppuccin.nix | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/overlays/catppuccin.nix b/overlays/catppuccin.nix index 5980626..4bc397a 100644 --- a/overlays/catppuccin.nix +++ b/overlays/catppuccin.nix @@ -1,8 +1,11 @@ {inputs, ...}: let - inherit (inputs.nixpkgs.lib) toHexString concatStrings; + inherit (inputs.nixpkgs.lib) toHexString concatStrings strings; + inherit (strings) fixedWidthString; + + padHex = n: fixedWidthString 2 "0" (toHexString n); in { - toHex = color: concatStrings ["#" (toHexString color.red) (toHexString color.green) (toHexString color.blue)]; - toHexNoHash = color: concatStrings [(toHexString color.red) (toHexString color.green) (toHexString color.blue)]; + toHex = color: concatStrings ["#" (padHex color.red) (padHex color.green) (padHex color.blue)]; + toHexNoHash = color: concatStrings [(padHex color.red) (padHex color.green) (padHex color.blue)]; toRGB = color: concatStrings ["rgb(" (toString color.red) "," (toString color.green) "," (toString color.blue) ")"]; toRGBA = color: a: concatStrings ["rgba(" (toString color.red) "," (toString color.green) "," (toString color.blue) "," (toString a) ")"]; } From ac1e00b92f331933ba26e34a772859bac1902bc7 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 24 Dec 2025 18:41:05 +0100 Subject: [PATCH 04/16] fuzzel config :) --- dots/.config/fuzzel/fuzzel.ini.nix | 9 +++++++++ modules/wm/hyprland/keybindings.nix | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/dots/.config/fuzzel/fuzzel.ini.nix b/dots/.config/fuzzel/fuzzel.ini.nix index 37e1563..b45a3c0 100644 --- a/dots/.config/fuzzel/fuzzel.ini.nix +++ b/dots/.config/fuzzel/fuzzel.ini.nix @@ -29,6 +29,15 @@ in { selection-match=${catppuccin.toHexNoHash colors.${accent}}ff counter=${catppuccin.toHexNoHash colors.overlay1}ff border=${catppuccin.toHexNoHash colors.${accent}}ff + + [main] + font=CaskaydiaCoveNerdFont:weight=semilight + terminal=kitty + + + [border] + width=2 + selection-radius=3 ''; }; } diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index 3615275..33a84dc 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -33,7 +33,7 @@ in { mods = ["SUPER"]; key = "SPACE"; dispatcher = "exec"; - params = "pkill fuzzel || fuzzel -T kitty"; + params = "pkill fuzzel || fuzzel"; } { From d77db0d379108ffda7cb67e6e0282cbea96198f6 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 31 Dec 2025 15:12:06 +0100 Subject: [PATCH 05/16] opacity change --- modules/wm/hyprland/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index b8c5a7c..2aa39bc 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -89,8 +89,8 @@ in { decoration = { rounding = 10; - activeOpacity = 0.9; - inactiveOpacity = 0.7; + activeOpacity = 1.0; + inactiveOpacity = 0.9; dimSpecial = 0.4; From 7af0994014d20c1fbf805f96b6fd73afac2bd2c1 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Fri, 2 Jan 2026 19:43:51 +0100 Subject: [PATCH 06/16] feat: printing --- machines/artemis/modules.nix | 1 + machines/terra/modules.nix | 1 + modules/network/default.nix | 1 + modules/network/printing.nix | 24 ++++++++++++++++++++++++ 4 files changed, 27 insertions(+) create mode 100644 modules/network/printing.nix diff --git a/machines/artemis/modules.nix b/machines/artemis/modules.nix index 843dc8b..8436e12 100644 --- a/machines/artemis/modules.nix +++ b/machines/artemis/modules.nix @@ -50,6 +50,7 @@ ssh.enable = true; syncthing.enable = true; tailscale.enable = true; + printing.enable = true; }; apps = { diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index 52cae86..3294cd4 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -56,6 +56,7 @@ ssh.enable = true; syncthing.enable = true; tailscale.enable = true; + printing.enable = true; }; apps = { diff --git a/modules/network/default.nix b/modules/network/default.nix index 143414f..9391087 100644 --- a/modules/network/default.nix +++ b/modules/network/default.nix @@ -4,5 +4,6 @@ ./ssh.nix ./syncthing.nix ./tailscale.nix + ./printing.nix ]; } diff --git a/modules/network/printing.nix b/modules/network/printing.nix new file mode 100644 index 0000000..49be0c5 --- /dev/null +++ b/modules/network/printing.nix @@ -0,0 +1,24 @@ +{ + lib, + config, + ... +}: let + inherit (lib) mkEnableOption mkIf; + cfg = config.horseman.network.printing; +in { + options = { + horseman.network.printing = { + enable = mkEnableOption "Turns on standard printing config"; + }; + }; + + config = mkIf cfg.enable { + services.printing.enable = true; + + services.avahi = { + enable = true; + nssmdns4 = true; + openFirewall = true; + }; + }; +} From 81e9e78a71a285f8c248e57c261f2983d9b0efb8 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Fri, 2 Jan 2026 19:44:03 +0100 Subject: [PATCH 07/16] remove drag lock --- modules/wm/hyprland/default.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index 2aa39bc..eab72ce 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -133,8 +133,6 @@ in { sensitivity = 0.0; touchpad.naturalScroll = true; numlockByDefault = true; - - touchpad.dragLock = 1; }; group = { From 8b9519c7ee91c1866622f68317180be29213c667 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Fri, 2 Jan 2026 23:38:43 +0100 Subject: [PATCH 08/16] auto login on greetd --- machines/terra/modules.nix | 1 + modules/boot/greeter/greetd.nix | 27 +++++++++++++++++++++------ 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index 3294cd4..a00735c 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -18,6 +18,7 @@ loader.systemd.enable = true; greeter.greetd.enable = true; greeter.greetd.session = "Hyprland"; + greeter.greetd.autoLogin = true; refind.enable = true; }; diff --git a/modules/boot/greeter/greetd.nix b/modules/boot/greeter/greetd.nix index 535e95f..ffe9644 100644 --- a/modules/boot/greeter/greetd.nix +++ b/modules/boot/greeter/greetd.nix @@ -12,6 +12,10 @@ in { horseman.boot.greeter.greetd = { enable = mkEnableOption "Greetd Greeter"; session = mkOption {type = types.str;}; + autoLogin = mkOption { + type = types.bool; + default = false; + }; }; }; @@ -22,12 +26,23 @@ in { services.greetd = { enable = true; - settings = { - default_session = { - user = homeCfg.username; - command = "${pkgs.tuigreet}/bin/tuigreet --time --remember --remember-session --greeting 'Please authenticate to continue' --asterisks --asterisks-char '*' --theme 'border=74;text=cyan;prompt=green;time=cyan;action=cyan;button=cyan;container=black;input=238' --cmd ${cfg.session}"; - }; - }; + settings = + { + default_session = { + user = homeCfg.username; + command = "${pkgs.tuigreet}/bin/tuigreet --time --remember --remember-session --greeting 'Please authenticate to continue' --asterisks --asterisks-char '*' --theme 'border=74;text=cyan;prompt=green;time=cyan;action=cyan;button=cyan;container=black;input=238' --cmd ${cfg.session}"; + }; + } + // ( + if cfg.autoLogin + then { + initial_session = { + user = homeCfg.username; + command = cfg.session; + }; + } + else {} + ); }; systemd.services.greetd.serviceConfig = { From 304570fd739e4dcce165e963da4f486f104f76a6 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Tue, 6 Jan 2026 13:17:59 +0100 Subject: [PATCH 09/16] terra wifi --- machines/terra/modules.nix | 1 + modules/hardware/wifi.nix | 4 ++++ secrets/wifi.age | 37 +++++++++++++++++++------------------ 3 files changed, 24 insertions(+), 18 deletions(-) diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index a00735c..92a10dc 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -51,6 +51,7 @@ hardware = { gpu.nvidia.enable = true; audio.enable = true; + wifi.enable = true; }; network = { diff --git a/modules/hardware/wifi.nix b/modules/hardware/wifi.nix index 5806756..9acb5b3 100644 --- a/modules/hardware/wifi.nix +++ b/modules/hardware/wifi.nix @@ -30,6 +30,10 @@ in { pskRaw = "ext:psk_ruiter"; }; + "TMNL-6DA8C1" = { + pskRaw = "ext:psk_tmnl6da8c1"; + }; + "kargadoor" = { pskRaw = "ext:psk_kargadoor"; }; diff --git a/secrets/wifi.age b/secrets/wifi.age index fe6bd05..4d9d360 100644 --- a/secrets/wifi.age +++ b/secrets/wifi.age @@ -1,20 +1,21 @@ -----BEGIN AGE ENCRYPTED FILE----- -YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IC9tczZkdyBaZjlp -Qi80a2lrUFBUT05KUVk2RVI3ZW5kZzVURldwRWJLenBVdkFobmhZCkcrRmlEWWRq -akEwaVhxVlVWWG1qaUdkY04wK05IWDJodHFxSEJYOFFheGcKLT4gc3NoLWVkMjU1 -MTkgZ1BJZFpBIDdkT1NjVitRQWJWOFV2WHVEcDdOL253MHRNcWhsYTkrUG5kQVFK -cFZXbFUKOXlQa1RENzQxYkRaUXZPdGdoeVp2bEhMeWJ2dWpON1JuazV1cmdLRk9O -QQotPiBzc2gtZWQyNTUxOSBXeUlGekEgZHZSQXZhdVJldU43aGUvRE92RDlJQ2ha -U3JCOXRjZkhCZnduNURWTjF3MAprZWczQXhWTjY0dldTMXd0RmlXSUhVOHhhTElH -YVRNZkZaN1VFeDhOcDFRCi0+IHNzaC1lZDI1NTE5IGRiT2VoQSBBWWlzQUV2RWxv -ZXFQOFJaR0FYSS9sRjZhdUZhOWE1OTBxTTNPTkZSUmx3CkdSTHRrSjJQOXBiWXBO -eUtvMjZlM25KNXU4dDYwaVB2cEkzMHJnVVBFbG8KLT4gc3NoLWVkMjU1MTkgdHYv -Q3pnIFVOMTVjSGFncHZxMkhyMzZ6V2FwaXZGNFBKODMrcnA3d3hlRERVRUduRVEK -TzdKc291QTBMSzYrcURMUEFQd3dEUk9vYVJPMWdhWnFWaFIxK3ZCZFMzZwotPiB+ -VCR2TTMvLWdyZWFzZQp5NEx4SHNOMlBXZ0xrc1lUZWc4WWV2RERJUQotLS0gZ01P -V2Z5WGFKclFhTm8wekVmZllQSnhwaW9MbzJPSVIyWkJta3Z6SStHNAo9+mXqaBH3 -yQaKE5s6TPR6AMf4ZqZ3/TtMmruR9O0Lv6uWtvE3nf1b+QobKhFmUX/J+bX9eHI3 -JxSKc6Xg8uCdfaD+vqtqbbbW9uXv2LAIOuFCVqDcEHFlt5dBIhUB5jvWd0igdI+F -C++o85pzminNN79bFGwqhJ6yUHhE+vsOaPGCE9pLooXRm4uFbecX2gXU28ftUErC -dX9U3G2kdJj5+6RE+oeyyDapjQWyaPCzT5i08HyGx+p2gtUW6BWM705y +YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IC9tczZkdyAybnc2 +YTBRMUpRT0E3alBWZXlieDlWK3crVkg1aGFLcEJKWXdQeHVwYlFNClN0VEYwQ216 +UFB2dzEwTlY1K1NTSHJXMEZTNlRZWGRRQ0tuejBZTUs1Z1kKLT4gc3NoLWVkMjU1 +MTkgZ1BJZFpBIGdhQmk1ZmpCR2xKSmE4RklWb0dZd2d6OHh0ZVVTR2xRV25GdmFH +aFRRbkEKcHViTHQvMm4ydm1MeVo2aEpJQ0VWZlJCamhVZkJoZ1I1L1o3bFdhdEdp +YwotPiBzc2gtZWQyNTUxOSBXeUlGekEgK2VMd25EOUp5S0pDSlNMTFZkenlXd09W +eG5CS2FCWUE2azBicGZ3MHIxYwpNKy9ySUcrUWlLM0hhQXIrTy9QQkhleUhSTUN0 +bmRIR2d2ZjFOR2lCV3M4Ci0+IHNzaC1lZDI1NTE5IGRiT2VoQSBhdzdGZHNOemZt +dFFxWnhpeFZ5aFRydWhPMXMrWHl0Ny9FNFhlTmtLQzJ3CmtHWWdldlVMdkg2aFgv +MDJHWEFySzI0VEhGaHd2VnVEcVUzU1JJbFF4dzAKLT4gc3NoLWVkMjU1MTkgdHYv +Q3pnIHlWRDUwcTlKRnd0N0VpUWJPd2UwYzBYc1JvbFVnRXlicVROSGZTZytvbTAK +SWVBRmVPbDUyVVV0N1daNmpLQjVESm1ZL0xZcTZGT0RGbEJmRW02alcvZwotPiAu +Pi1ncmVhc2UgaXlfYyFzCk83RXV4clFtZ29ZdUw0OFVEZE5LR2ZEb2lCWjZqcGsK +LS0tIEtBUnpnL2sxR3VZWCswTEJ4cGg2RXhDZndxaVdXVUFhQWc3d1hYL284OHcK +s1JLJWVTPMOkTdwQ9KjP8X/J+J9dpRM9TC7/9KzupLTni5iuaDuHu4yqcEreBZR6 +9bDLNACBMDucZNy2XGSg2zE16fFQM584rcvHZ8Hvn0Ju+heMjvjKwkAJ6hSapZa+ +LrQaHx8JeFgaH+aXMbi7Ysz3lbKwhecyG8tSG/KocoSXWOehp+BGPeLIX02G2a2r +g0KtTNNGWEaar10PNTkYQlxyQG5y9gugLWsfiwB1LjSc+ZZJVIpMRmyFo1ekfus2 +Db3jUp+de9+lxetURzUVWO7biPRha3WnS/1I -----END AGE ENCRYPTED FILE----- From 954bf2d4babffbcf0786d9ba38e293a46521256a Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 7 Jan 2026 16:39:44 +0100 Subject: [PATCH 10/16] add nix-hyprland --- dots/.config/hypr/hypridle.conf.nix | 35 - dots/.config/hypr/hyprland.conf.nix | 387 ------- dots/.config/hypr/hyprlock.conf.nix | 76 -- dots/.config/hypr/hyprpaper.conf.nix | 34 - dots/default.nix | 4 - flake.lock | 57 +- flake.nix | 7 +- lib/default.nix | 5 - lib/hyprland/default.nix | 6 - lib/hyprland/gestures.nix | 61 -- lib/hyprland/standard-options.nix | 1407 -------------------------- machines/artemis/modules.nix | 32 +- machines/terra/modules.nix | 46 +- modules/wm/hyprland/animations.nix | 18 +- modules/wm/hyprland/default.nix | 22 +- modules/wm/hyprland/keybindings.nix | 970 +++++++++--------- modules/wm/hyprland/options.nix | 231 +---- 17 files changed, 619 insertions(+), 2779 deletions(-) delete mode 100644 dots/.config/hypr/hypridle.conf.nix delete mode 100644 dots/.config/hypr/hyprland.conf.nix delete mode 100644 dots/.config/hypr/hyprlock.conf.nix delete mode 100644 dots/.config/hypr/hyprpaper.conf.nix delete mode 100644 lib/default.nix delete mode 100644 lib/hyprland/default.nix delete mode 100644 lib/hyprland/gestures.nix delete mode 100644 lib/hyprland/standard-options.nix diff --git a/dots/.config/hypr/hypridle.conf.nix b/dots/.config/hypr/hypridle.conf.nix deleted file mode 100644 index a8bc82f..0000000 --- a/dots/.config/hypr/hypridle.conf.nix +++ /dev/null @@ -1,35 +0,0 @@ -{ - lib, - config, - ... -}: let - inherit (lib) mkIf mkEnableOption; - inherit (builtins) concatStringsSep; - - cfg = config.horseman.dots.hypr.hypridle; - username = config.horseman.username; - hypr = config.horseman.wm.hyprland.config; -in { - options = { - horseman.dots.hypr.hypridle = { - enable = mkEnableOption "~/.config/hypr/hypridle.conf"; - }; - }; - - config = mkIf cfg.enable { - home-manager.users.${username}.xdg.configFile."hypr/hypridle.conf".text = '' - general { - lock_cmd = ${hypr.sleep.lockCommand} - } - - ${concatStringsSep "\n\n" (map (lis: '' - listener { - timeout = ${toString lis.timeout} - on-timeout = ${lis.onTimeout} - on-resume = ${lis.onResume} - } - '') - hypr.sleep.listeners)} - ''; - }; -} diff --git a/dots/.config/hypr/hyprland.conf.nix b/dots/.config/hypr/hyprland.conf.nix deleted file mode 100644 index 0f39505..0000000 --- a/dots/.config/hypr/hyprland.conf.nix +++ /dev/null @@ -1,387 +0,0 @@ -{ - lib, - config, - ... -}: let - inherit (lib) mkIf trivial strings mkEnableOption; - inherit (builtins) concatStringsSep elem genList elemAt length; - inherit (trivial) boolToString; - inherit (strings) floatToString; - - cfg = config.horseman.dots.hypr.hyprland; - username = config.horseman.username; - hypr = config.horseman.wm.hyprland.config; -in { - options = { - horseman.dots.hypr.hyprland = { - enable = mkEnableOption "~/.config/hypr/hyprland.conf"; - }; - }; - - config = mkIf cfg.enable { - home-manager.users.${username}.xdg.configFile."hypr/hyprland.conf".text = '' - ${concatStringsSep "\n" (map (kb: "bind${concatStringsSep "" kb.flags} = ${concatStringsSep " " kb.mods}, ${kb.key}, ${kb.dispatcher}${ - if (elem "m" kb.flags) # Mouse binds take one argument less - then "" - else ", ${kb.params}" - }") - hypr.keybindings.binds)} - - ${concatStringsSep "\n" (map (gs: toString gs) hypr.gestures.gestures)} - - ${concatStringsSep "\n\n" (map (sm: '' - bind${concatStringsSep "" sm.enterBind.flags} = ${concatStringsSep " " sm.enterBind.mods}, ${sm.enterBind.key}, submap, ${sm.name} - submap = ${sm.name} - - ${concatStringsSep "\n" (map (kb: "bind${concatStringsSep "" kb.flags} = ${concatStringsSep " " kb.mods}, ${kb.key}, ${kb.dispatcher}${ - if (elem "m" kb.flags) # Mouse binds take one argument less - then "" - else ", ${kb.params}" - }") - sm.binds)} - - bind${concatStringsSep "" sm.exitBind.flags} = ${concatStringsSep " " sm.exitBind.mods}, ${sm.exitBind.key}, submap, reset - submap = reset - '') - hypr.keybindings.submaps)} - - ${concatStringsSep "\n" (map (x: "exec-once = " + x) hypr.execOnce)} - - ${concatStringsSep "\n" (map (x: "env = " + x) hypr.env)} - - general { - border_size = ${toString hypr.general.borderSize} - gaps_in = ${toString hypr.general.gapsIn} - gaps_out = ${toString hypr.general.gapsOut} - gaps_workspaces = ${toString hypr.general.gapsWorkspaces} - col.inactive_border = ${hypr.general.col.inactiveBorder} - col.active_border = ${hypr.general.col.activeBorder} - col.nogroup_border = ${hypr.general.col.nogroupBorder} - col.nogroup_border_active = ${hypr.general.col.nogroupBorderActive} - layout = ${hypr.general.layout} - no_focus_fallback = ${boolToString hypr.general.noFocusFallback} - resize_on_border = ${boolToString hypr.general.resizeOnBorder} - extend_border_grab_area = ${toString hypr.general.extendBorderGrabArea} - hover_icon_on_border = ${boolToString hypr.general.hoverIconOnBorder} - allow_tearing = ${boolToString hypr.general.allowTearing} - resize_corner = ${toString hypr.general.resizeCorner} - - snap { - enabled = ${boolToString hypr.general.snap.enabled} - window_gap = ${toString hypr.general.snap.windowGap} - monitor_gap = ${toString hypr.general.snap.monitorGap} - border_overlap = ${boolToString hypr.general.snap.borderOverlap} - } - } - - decoration { - rounding = ${toString hypr.decoration.rounding} - rounding_power = ${toString hypr.decoration.roundingPower} - active_opacity = ${toString hypr.decoration.activeOpacity} - inactive_opacity = ${toString hypr.decoration.inactiveOpacity} - fullscreen_opacity = ${toString hypr.decoration.fullscreenOpacity} - dim_inactive = ${boolToString hypr.decoration.dimInactive} - dim_strength = ${toString hypr.decoration.dimStrength} - dim_special = ${toString hypr.decoration.dimSpecial} - dim_around = ${toString hypr.decoration.dimAround} - screen_shader = ${toString hypr.decoration.screenShader} - border_part_of_window = ${boolToString hypr.decoration.borderPartOfWindow} - - blur { - enabled = ${boolToString hypr.decoration.blur.enabled} - size = ${toString hypr.decoration.blur.size} - passes = ${toString hypr.decoration.blur.passes} - ignore_opacity = ${boolToString hypr.decoration.blur.ignoreOpacity} - new_optimizations = ${boolToString hypr.decoration.blur.newOptimizations} - xray = ${boolToString hypr.decoration.blur.xray} - noise = ${toString hypr.decoration.blur.noise} - contrast = ${toString hypr.decoration.blur.contrast} - brightness = ${toString hypr.decoration.blur.brightness} - vibrancy = ${toString hypr.decoration.blur.vibrancy} - vibrancy_darkness = ${toString hypr.decoration.blur.vibrancyDarkness} - special = ${boolToString hypr.decoration.blur.special} - popups = ${boolToString hypr.decoration.blur.popups} - popups_ignorealpha = ${toString hypr.decoration.blur.popupsIgnorealpha} - input_methods = ${boolToString hypr.decoration.blur.inputMethods} - input_methods_ignorealpha = ${toString hypr.decoration.blur.inputMethodsIgnorealpha} - } - - shadow { - enabled = ${boolToString hypr.decoration.shadow.enabled} - range = ${toString hypr.decoration.shadow.range} - render_power = ${toString hypr.decoration.shadow.renderPower} - sharp = ${boolToString hypr.decoration.shadow.sharp} - ignore_window = ${boolToString hypr.decoration.shadow.ignoreWindow} - color = ${toString hypr.decoration.shadow.color} - ${ - if (hypr.decoration.shadow.colorInactive == null) - then "" - else "color_inactive = ${toString hypr.decoration.shadow.colorInactive}" - } - offset = ${toString hypr.decoration.shadow.offset.x} ${toString hypr.decoration.shadow.offset.y} - scale = ${toString hypr.decoration.shadow.scale} - } - } - - animations { - enabled = ${boolToString hypr.animations.enabled} - workspace_wraparound = ${boolToString hypr.animations.workspaceWraparound} - - ${concatStringsSep "\n " (map (bez: "bezier = ${bez.name}, ${floatToString bez.startX}, ${floatToString bez.startY}, ${floatToString bez.endX}, ${floatToString bez.endY}") hypr.animations.beziers)} - - ${concatStringsSep "\n " (map (anim: "animation = ${anim.name}, ${toString anim.on}, ${floatToString anim.speed}, ${anim.curve}, ${anim.style}") hypr.animations.animations)} - } - - input { - kb_model = ${toString hypr.input.kbModel} - kb_layout = ${toString hypr.input.kbLayout} - kb_variant = ${toString hypr.input.kbVariant} - kb_options = ${toString hypr.input.kbOptions} - kb_rules = ${toString hypr.input.kbRules} - kb_file = ${toString hypr.input.kbFile} - numlock_by_default = ${boolToString hypr.input.numlockByDefault} - resolve_binds_by_sym = ${boolToString hypr.input.resolveBindsBySym} - repeat_rate = ${toString hypr.input.repeatRate} - repeat_delay = ${toString hypr.input.repeatDelay} - sensitivity = ${toString hypr.input.sensitivity} - accel_profile = ${toString hypr.input.accelProfile} - force_no_accel = ${boolToString hypr.input.forceNoAccel} - left_handed = ${boolToString hypr.input.leftHanded} - scroll_points = ${toString hypr.input.scrollPoints} - scroll_method = ${toString hypr.input.scrollMethod} - scroll_button = ${toString hypr.input.scrollButton} - scroll_button_lock = ${boolToString hypr.input.scrollButtonLock} - scroll_factor = ${toString hypr.input.scrollFactor} - natural_scroll = ${boolToString hypr.input.naturalScroll} - follow_mouse = ${toString hypr.input.followMouse} - follow_mouse_threshold = ${toString hypr.input.followMouseThreshold} - focus_on_close = ${toString hypr.input.focusOnClose} - mouse_refocus = ${boolToString hypr.input.mouseRefocus} - float_switch_override_focus = ${toString hypr.input.floatSwitchOverrideFocus} - special_fallthrough = ${boolToString hypr.input.specialFallthrough} - off_window_axis_events = ${toString hypr.input.offWindowAxisEvents} - emulate_discrete_scroll = ${toString hypr.input.emulateDiscreteScroll} - - touchpad { - disable_while_typing = ${boolToString hypr.input.touchpad.disableWhileTyping} - natural_scroll = ${boolToString hypr.input.touchpad.naturalScroll} - scroll_factor = ${toString hypr.input.touchpad.scrollFactor} - middle_button_emulation = ${boolToString hypr.input.touchpad.middleButtonEmulation} - tap_button_map = ${toString hypr.input.touchpad.tapButtonMap} - clickfinger_behavior = ${boolToString hypr.input.touchpad.clickfingerBehavior} - tap-to-click = ${boolToString hypr.input.touchpad.tapToClick} - drag_lock = ${toString hypr.input.touchpad.dragLock} - tap-and-drag = ${toString hypr.input.touchpad.tapAndDrag} - flip_x = ${boolToString hypr.input.touchpad.flipX} - flip_y = ${boolToString hypr.input.touchpad.flipY} - } - - touchdevice { - transform = ${toString hypr.input.touchdevice.transform} - output = ${toString hypr.input.touchdevice.output} - enabled = ${boolToString hypr.input.touchdevice.enabled} - } - - tablet { - transform = ${toString hypr.input.tablet.transform} - output = ${toString hypr.input.tablet.output} - region_position = ${toString hypr.input.tablet.regionPosition.x} ${toString hypr.input.tablet.regionPosition.y} - absolute_region_position = ${boolToString hypr.input.tablet.absoluteRegionPosition} - region_size = ${toString hypr.input.tablet.regionSize.x} ${toString hypr.input.tablet.regionSize.y} - relative_input = ${boolToString hypr.input.tablet.relativeInput} - left_handed = ${boolToString hypr.input.tablet.leftHanded} - active_area_size = ${toString hypr.input.tablet.activeAreaSize.x} ${toString hypr.input.tablet.activeAreaSize.y} - active_area_position = ${toString hypr.input.tablet.activeAreaPosition.x} ${toString hypr.input.tablet.activeAreaPosition.y} - } - } - - gestures { - workspace_swipe_distance = ${toString hypr.gestures.workspaceSwipeDistance} - workspace_swipe_touch = ${boolToString hypr.gestures.workspaceSwipeTouch} - workspace_swipe_invert = ${boolToString hypr.gestures.workspaceSwipeInvert} - workspace_swipe_touch_invert = ${boolToString hypr.gestures.workspaceSwipeTouchInvert} - workspace_swipe_min_speed_to_force = ${toString hypr.gestures.workspaceSwipeMinSpeedToForce} - workspace_swipe_cancel_ratio = ${floatToString hypr.gestures.workspaceSwipeCancelRatio} - workspace_swipe_create_new = ${boolToString hypr.gestures.workspaceSwipeCreateNew} - workspace_swipe_direction_lock = ${boolToString hypr.gestures.workspaceSwipeDirectionLock} - workspace_swipe_direction_lock_threshold = ${toString hypr.gestures.workspaceSwipeDirectionLockThreshold} - workspace_swipe_forever = ${boolToString hypr.gestures.workspaceSwipeForever} - workspace_swipe_use_r = ${boolToString hypr.gestures.workspaceSwipeUseR} - } - - group { - auto_group = ${boolToString hypr.group.autoGroup} - insert_after_current = ${boolToString hypr.group.insertAfterCurrent} - focus_removed_window = ${boolToString hypr.group.focusRemovedWindow} - drag_into_group = ${toString hypr.group.dragIntoGroup} - merge_groups_on_drag = ${boolToString hypr.group.mergeGroupsOnDrag} - merge_groups_on_groupbar = ${boolToString hypr.group.mergeGroupsOnGroupbar} - merge_floated_into_tiled_on_groupbar = ${boolToString hypr.group.mergeFloatedIntoTiledOnGroupbar} - group_on_movetoworkspace = ${boolToString hypr.group.groupOnMovetoworkspace} - col.border_active = ${toString hypr.group.col.borderActive} - col.border_inactive = ${toString hypr.group.col.borderInactive} - col.border_locked_active = ${toString hypr.group.col.borderLockedActive} - col.border_locked_inactive = ${toString hypr.group.col.borderLockedInactive} - - groupbar { - enabled = ${boolToString hypr.group.groupbar.enabled} - font_family = ${toString hypr.group.groupbar.fontFamily} - font_size = ${toString hypr.group.groupbar.fontSize} - font_weight_active = ${toString hypr.group.groupbar.fontWeightActive} - font_weight_inactive = ${toString hypr.group.groupbar.fontWeightInactive} - gradients = ${boolToString hypr.group.groupbar.gradients} - height = ${toString hypr.group.groupbar.height} - indicator_gap = ${toString hypr.group.groupbar.indicatorGap} - indicator_height = ${toString hypr.group.groupbar.indicatorHeight} - stacked = ${boolToString hypr.group.groupbar.stacked} - priority = ${toString hypr.group.groupbar.priority} - render_titles = ${boolToString hypr.group.groupbar.renderTitles} - text_offset = ${toString hypr.group.groupbar.textOffset} - scrolling = ${boolToString hypr.group.groupbar.scrolling} - rounding = ${toString hypr.group.groupbar.rounding} - gradient_rounding = ${toString hypr.group.groupbar.gradientRounding} - round_only_edges = ${boolToString hypr.group.groupbar.roundOnlyEdges} - gradient_round_only_edges = ${boolToString hypr.group.groupbar.gradientRoundOnlyEdges} - text_color = ${toString hypr.group.groupbar.textColor} - col.active = ${toString hypr.group.groupbar.col.active} - col.inactive = ${toString hypr.group.groupbar.col.inactive} - col.locked_active = ${toString hypr.group.groupbar.col.lockedActive} - col.locked_inactive = ${toString hypr.group.groupbar.col.lockedInactive} - gaps_in = ${toString hypr.group.groupbar.gapsIn} - gaps_out = ${toString hypr.group.groupbar.gapsOut} - keep_upper_gap = ${boolToString hypr.group.groupbar.keepUpperGap} - } - } - - misc { - disable_hyprland_logo = ${boolToString hypr.misc.disableHyprlandLogo} - disable_splash_rendering = ${boolToString hypr.misc.disableSplashRendering} - col.splash = ${toString hypr.misc.col.splash} - font_family = ${toString hypr.misc.fontFamily} - splash_font_family = ${toString hypr.misc.splashFontFamily} - force_default_wallpaper = ${toString hypr.misc.forceDefaultWallpaper} - vfr = ${toString hypr.misc.vfr} - vrr = ${toString hypr.misc.vrr} - mouse_move_enables_dpms = ${boolToString hypr.misc.mouseMoveEnablesDPMS} - key_press_enables_dpms = ${boolToString hypr.misc.keyPressEnablesDPMS} - always_follow_on_dnd = ${boolToString hypr.misc.alwaysFollowOnDnd} - layers_hog_keyboard_focus = ${boolToString hypr.misc.layersHogKeyboardFocus} - animate_manual_resizes = ${boolToString hypr.misc.animateManualResizes} - animate_mouse_windowdragging = ${boolToString hypr.misc.animateMouseWindowdragging} - disable_autoreload = ${boolToString hypr.misc.disableAutoreload} - enable_swallow = ${boolToString hypr.misc.enableSwallow} - swallow_regex = ${toString hypr.misc.swallowRegex} - swallow_exception_regex = ${toString hypr.misc.swallowExceptionRegex} - focus_on_activate = ${boolToString hypr.misc.focusOnActivate} - mouse_move_focuses_monitor = ${boolToString hypr.misc.mouseMoveFocusesMonitor} - allow_session_lock_restore = ${boolToString hypr.misc.allowSessionLockRestore} - background_color = ${toString hypr.misc.backgroundColor} - close_special_on_empty = ${boolToString hypr.misc.closeSpecialOnEmpty} - new_window_takes_over_fullscreen = ${toString hypr.misc.newWindowTakesOverFullscreen} - exit_window_retains_fullscreen = ${boolToString hypr.misc.exitWindowRetainsFullscreen} - initial_workspace_tracking = ${toString hypr.misc.initialWorkspaceTracking} - middle_click_paste = ${boolToString hypr.misc.middleClickPaste} - render_unfocused_fps = ${toString hypr.misc.renderUnfocusedFps} - disable_xdg_env_checks = ${boolToString hypr.misc.disableXdgEnvChecks} - disable_hyprland_guiutils_check = ${boolToString hypr.misc.disableHyprlandGuiUtilsCheck} - lockdead_screen_delay = ${toString hypr.misc.lockdeadScreenDelay} - enable_anr_dialog = ${boolToString hypr.misc.enableAnrDialog} - anr_missed_pings = ${toString hypr.misc.anrMissedPings} - } - - binds { - pass_mouse_when_bound = ${boolToString hypr.binds.passMouseWhenBound} - scroll_event_delay = ${toString hypr.binds.scrollEventDelay} - workspace_back_and_forth = ${boolToString hypr.binds.workspaceBackAndForth} - hide_special_on_workspace_change = ${boolToString hypr.binds.hideSpecialOnWorkspaceChange} - allow_workspace_cycles = ${boolToString hypr.binds.allowWorkspaceCycles} - workspace_center_on = ${toString hypr.binds.workspaceCenterOn} - focus_preferred_method = ${toString hypr.binds.focusPreferredMethod} - ignore_group_lock = ${boolToString hypr.binds.ignoreGroupLock} - movefocus_cycles_fullscreen = ${boolToString hypr.binds.movefocusCyclesFullscreen} - movefocus_cycles_groupfirst = ${boolToString hypr.binds.movefocusCyclesGroupfirst} - disable_keybind_grabbing = ${boolToString hypr.binds.disableKeybindGrabbing} - window_direction_monitor_fallback = ${boolToString hypr.binds.windowDirectionMonitorFallback} - allow_pin_fullscreen = ${boolToString hypr.binds.allowPinFullscreen} - drag_threshold = ${toString hypr.binds.dragThreshold} - } - - xwayland { - enabled = ${boolToString hypr.xwayland.enabled} - use_nearest_neighbor = ${boolToString hypr.xwayland.useNearestNeighbor} - force_zero_scaling = ${boolToString hypr.xwayland.forceZeroScaling} - create_abstract_socket = ${boolToString hypr.xwayland.createAbstractSocket} - } - - opengl { - nvidia_anti_flicker = ${boolToString hypr.opengl.nvidiaAntiFlicker} - } - - render { - direct_scanout = ${toString hypr.render.directScanout} - expand_undersized_textures = ${boolToString hypr.render.expandUndersizedTextures} - xp_mode = ${boolToString hypr.render.xpMode} - ctm_animation = ${toString hypr.render.ctmAnimation} - cm_fs_passthrough = ${toString hypr.render.cmFsPassthrough} - cm_enabled = ${boolToString hypr.render.cmEnabled} - send_content_type = ${boolToString hypr.render.sendContentType} - } - - cursor { - sync_gsettings_theme = ${boolToString hypr.cursor.syncGsettingsTheme} - no_hardware_cursors = ${toString hypr.cursor.noHardwareCursors} - no_break_fs_vrr = ${toString hypr.cursor.noBreakFsVrr} - min_refresh_rate = ${toString hypr.cursor.minRefreshRate} - hotspot_padding = ${toString hypr.cursor.hotspotPadding} - inactive_timeout = ${toString hypr.cursor.inactiveTimeout} - no_warps = ${boolToString hypr.cursor.noWarps} - persistent_warps = ${boolToString hypr.cursor.persistentWarps} - warp_on_change_workspace = ${toString hypr.cursor.warpOnChangeWorkspace} - warp_on_toggle_special = ${toString hypr.cursor.warpOnToggleSpecial} - default_monitor = ${toString hypr.cursor.defaultMonitor} - zoom_factor = ${toString hypr.cursor.zoomFactor} - zoom_rigid = ${boolToString hypr.cursor.zoomRigid} - enable_hyprcursor = ${boolToString hypr.cursor.enableHyprcursor} - hide_on_key_press = ${boolToString hypr.cursor.hideOnKeyPress} - hide_on_touch = ${boolToString hypr.cursor.hideOnTouch} - use_cpu_buffer = ${toString hypr.cursor.useCpuBuffer} - warp_back_after_non_mouse_input = ${boolToString hypr.cursor.warpBackAfterNonMouseInput} - } - - ecosystem { - no_update_news = ${boolToString hypr.ecosystem.noUpdateNews} - no_donation_nag = ${boolToString hypr.ecosystem.noDonationNag} - enforce_permissions = ${boolToString hypr.ecosystem.enforcePermissions} - } - - dwindle { - pseudotile = ${boolToString hypr.dwindle.pseudotile} - preserve_split = ${boolToString hypr.dwindle.preserveSplit} - } - - master { - new_status = ${toString hypr.master.newStatus} - } - - ${concatStringsSep "\n" (map (mon: "monitor = ${mon.output}, ${mon.resolution}@${mon.refreshRate}, ${toString mon.x}x${toString mon.y}, ${floatToString mon.scale}, transform, ${toString mon.transform}") hypr.monitors.displays)} - - ${ - if hypr.monitors.defaultMonitor - then "monitor = ,preferred, auto, auto" - else "" - } - - ${concatStringsSep "\n" (map (wr: "windowrule = " + wr) hypr.windowrules)} - - ${concatStringsSep "\n" (map (ws: "workspace = " + ws) hypr.workspaces)} - - ${ - concatStringsSep "\n" ( - if hypr.monitors.bindWorkspaces == "interlaced" - then (map (x: "workspace = ${toString (x + 1)}, persistent:true, monitor:${(elemAt hypr.monitors.displays (x - ((length hypr.monitors.displays) * (x / (length hypr.monitors.displays))))).output}") (genList (x: x) 10)) - else [] - ) - } - ''; - }; -} diff --git a/dots/.config/hypr/hyprlock.conf.nix b/dots/.config/hypr/hyprlock.conf.nix deleted file mode 100644 index 2082e15..0000000 --- a/dots/.config/hypr/hyprlock.conf.nix +++ /dev/null @@ -1,76 +0,0 @@ -{ - lib, - config, - ... -}: let - inherit (lib) mkIf mkEnableOption; - - cfg = config.horseman.dots.hypr.hyprlock; - username = config.horseman.username; -in { - options = { - horseman.dots.hypr.hyprlock = { - enable = mkEnableOption "~/.config/hypr/hyprlock.conf"; - }; - }; - - config = mkIf cfg.enable { - home-manager.users.${username}.xdg.configFile."hypr/hyprlock.conf".text = '' - $font = Monospace - - general { - hide_cursor = false - } - - animations { - enabled = true - bezier = linear, 1, 1, 0, 0 - animation = fadeIn, 1, 5, linear - animation = fadeOut, 1, 5, linear - animation = inputFieldDots, 1, 2, linear - } - - background { - monitor = - path = screenshot - blur_passes = 3 - } - - input-field { - monitor = - size = 20%, 5% - outline_thickness = 3 - inner_color = rgba(0, 0, 0, 0.0) # no fill - - outer_color = rgba(33ccffee) rgba(00ff99ee) 45deg - check_color = rgba(00ff99ee) rgba(ff6633ee) 120deg - fail_color = rgba(ff6633ee) rgba(ff0066ee) 40deg - - font_color = rgb(143, 143, 143) - fade_on_empty = false - rounding = 15 - - font_family = $font - placeholder_text = Input password... - fail_text = $PAMFAIL - - dots_spacing = 0.3 - - position = 0, -20 - halign = center - valign = center - } - - label { - monitor = - text = $TIME - font_size = 90 - font_family = $font - - position = 0, -50 - halign = center - valign = top - } - ''; - }; -} diff --git a/dots/.config/hypr/hyprpaper.conf.nix b/dots/.config/hypr/hyprpaper.conf.nix deleted file mode 100644 index 78dc0d6..0000000 --- a/dots/.config/hypr/hyprpaper.conf.nix +++ /dev/null @@ -1,34 +0,0 @@ -{ - lib, - config, - ... -}: let - inherit (lib) mkIf mkEnableOption; - inherit (builtins) concatStringsSep; - - cfg = config.horseman.dots.hypr.hyprpaper; - username = config.horseman.username; - hypr = config.horseman.wm.hyprland.config; -in { - options = { - horseman.dots.hypr.hyprpaper = { - enable = mkEnableOption "~/.config/hypr/hyprpaper.conf"; - }; - }; - - config = mkIf cfg.enable { - home-manager.users.${username}.xdg.configFile."hypr/hyprpaper.conf".text = '' - ${concatStringsSep "\n" (map (dis: - if dis.wallpaper != null - then '' - preload = ${dis.wallpaper} - wallpaper = ${dis.output}, ${dis.wallpaper} - '' - else "") - hypr.monitors.displays)} - - preload = /home/${username}/nix-config/misc/wallpaper.jpg - wallpaper = , /home/${username}/nix-config/misc/wallpaper.jpg - ''; - }; -} diff --git a/dots/default.nix b/dots/default.nix index 5ee014b..059ab0d 100644 --- a/dots/default.nix +++ b/dots/default.nix @@ -3,10 +3,6 @@ ./.warprc.nix ./.config/eza/theme.yml.nix ./.config/fuzzel/fuzzel.ini.nix - ./.config/hypr/hypridle.conf.nix - ./.config/hypr/hyprlock.conf.nix - ./.config/hypr/hyprland.conf.nix - ./.config/hypr/hyprpaper.conf.nix ./.config/kitty/kitty.conf.nix ./.config/wofi/style.css.nix ./.config/waybar/style.css.nix diff --git a/flake.lock b/flake.lock index 8bacbf8..463d13b 100644 --- a/flake.lock +++ b/flake.lock @@ -87,7 +87,61 @@ "type": "github" } }, + "home-manager_3": { + "inputs": { + "nixpkgs": [ + "nix-hyprland", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1767280655, + "narHash": "sha256-YmaYMduV5ko8zURUT1VLGDbVC1L/bxHS0NsiPoZ6bBM=", + "owner": "nix-community", + "repo": "home-manager", + "rev": "d49d2543f02dbd789ed032188c84570d929223cb", + "type": "github" + }, + "original": { + "owner": "nix-community", + "ref": "release-25.11", + "repo": "home-manager", + "type": "github" + } + }, + "nix-hyprland": { + "inputs": { + "home-manager": "home-manager_3", + "nixpkgs": "nixpkgs" + }, + "locked": { + "lastModified": 1767799636, + "narHash": "sha256-qBgbE4jC/VJaY86mNspzToyR08xacawAbMeZskejcJc=", + "path": "/home/horseman/Programming/nix-hyprland", + "type": "path" + }, + "original": { + "path": "/home/horseman/Programming/nix-hyprland", + "type": "path" + } + }, "nixpkgs": { + "locked": { + "lastModified": 1767325753, + "narHash": "sha256-yA/CuWyqm+AQo2ivGy6PlYrjZBQm7jfbe461+4HF2fo=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "64049ca74d63e971b627b5f3178d95642e61cedd", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-25.11", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_2": { "locked": { "lastModified": 1766201043, "narHash": "sha256-eplAP+rorKKd0gNjV3rA6+0WMzb1X1i16F5m5pASnjA=", @@ -130,7 +184,8 @@ "inputs": { "agenix": "agenix", "home-manager": "home-manager_2", - "nixpkgs": "nixpkgs", + "nix-hyprland": "nix-hyprland", + "nixpkgs": "nixpkgs_2", "plasma-manager": "plasma-manager" } }, diff --git a/flake.nix b/flake.nix index aa12078..1972966 100644 --- a/flake.nix +++ b/flake.nix @@ -19,6 +19,10 @@ url = "github:ryantm/agenix"; inputs.nixpkgs.follows = "nixpkgs"; }; + + nix-hyprland = { + url = "github:KoenDR06/nix-hyprland"; + }; }; outputs = { @@ -27,6 +31,7 @@ home-manager, plasma-manager, agenix, + nix-hyprland, ... } @ inputs: let inherit (self) outputs; @@ -57,12 +62,12 @@ inherit inputs outputs lib; }; modules = [ - ./lib ./modules ./dots ./machines/${host}/configuration.nix home-manager.nixosModules.home-manager agenix.nixosModules.default + nix-hyprland.nixosModules.default { home-manager.sharedModules = [plasma-manager.homeModules.plasma-manager]; } diff --git a/lib/default.nix b/lib/default.nix deleted file mode 100644 index fba2694..0000000 --- a/lib/default.nix +++ /dev/null @@ -1,5 +0,0 @@ -{...}: { - imports = [ - ./hyprland - ]; -} diff --git a/lib/hyprland/default.nix b/lib/hyprland/default.nix deleted file mode 100644 index a408962..0000000 --- a/lib/hyprland/default.nix +++ /dev/null @@ -1,6 +0,0 @@ -{...}: { - imports = [ - ./standard-options.nix - ./gestures.nix - ]; -} diff --git a/lib/hyprland/gestures.nix b/lib/hyprland/gestures.nix deleted file mode 100644 index 862c039..0000000 --- a/lib/hyprland/gestures.nix +++ /dev/null @@ -1,61 +0,0 @@ -{lib, ...}: let - inherit (lib) mkOption types; - inherit (builtins) concatStringsSep; - - # v0.52.1 - - # gesture = fingers, direction, action, options - gesture = - types.submodule { - options = { - fingers = mkOption { - type = types.ints.positive; - }; - direction = mkOption { - type = types.enum ["swipe" "horizontal" "vertical" "left" "right" "up" "down" "pinch" "pinchin" "pinchout"]; - }; - mods = mkOption { - type = types.listOf types.str; - default = []; - }; - scale = mkOption { - type = types.numbers.positive; - default = 1; - }; - action = mkOption { - type = types.enum ["dispatcher" "workspace" "move" "resize" "special" "close" "fullscreen" "float"]; - }; - options = mkOption { - type = types.listOf types.str; - default = []; - }; - }; - } - // { - }; -in { - options.horseman.wm.hyprland.config = { - gestures.gestures = mkOption { - type = types.listOf gesture; - default = []; - apply = gs: - map (it: - it - // { - __toString = gs: "gesture = ${concatStringsSep ", " ( - [ - (toString gs.fingers) - (gs.direction) - ] - ++ map (it: "mod: ${it}") gs.mods - ++ [ - "scale: ${toString gs.scale}" - (gs.action) - ] - ++ gs.options - )}"; - }) - gs; - }; - }; -} diff --git a/lib/hyprland/standard-options.nix b/lib/hyprland/standard-options.nix deleted file mode 100644 index 05b3827..0000000 --- a/lib/hyprland/standard-options.nix +++ /dev/null @@ -1,1407 +0,0 @@ -{lib, ...}: let - inherit (lib) mkOption types; - - # v0.52.1 - vec2 = types.submodule { - options = { - x = mkOption {type = types.int;}; - y = mkOption {type = types.int;}; - }; - }; - fontWeight = types.enum ["thin" "ultralight" "light" "semilight" "book" "normal" "medium" "semibold" "bold" "ultrabold" "heavy" "ultraheavy"]; -in { - options.horseman.wm.hyprland.config = { - general = { - borderSize = mkOption { - description = "size of the border around windows"; - type = types.int; - default = 1; - }; - gapsIn = mkOption { - description = "gaps between windows, also supports css style gaps (top, right, bottom, left -> 5,10,15,20)"; - type = types.int; - default = 5; - }; - gapsOut = mkOption { - description = "gaps between windows and monitor edges, also supports css style gaps (top, right, bottom, left -> 5,10,15,20)"; - type = types.int; - default = 20; - }; - floatGaps = mkOption { - description = "gaps between windows and monitor edges for floating windows, also supports css style gaps (top, right, bottom, left -> 5 10 15 20). -1 means default"; - type = types.int; - default = 0; - }; - gapsWorkspaces = mkOption { - description = "gaps between workspaces. Stacks with gapsOut."; - type = types.int; - default = 0; - }; - col.inactiveBorder = mkOption { - description = "border color for inactive windows"; - type = types.str; - default = "0xff444444"; - }; - col.activeBorder = mkOption { - description = "border color for the active window"; - type = types.str; - default = "0xffffffff"; - }; - col.nogroupBorder = mkOption { - description = "inactive border color for window that cannot be added to a group (see `denywindowfromgroup` dispatcher)"; - type = types.str; - default = "0xffffaaff"; - }; - col.nogroupBorderActive = mkOption { - description = "active border color for window that cannot be added to a group"; - type = types.str; - default = "0xffff00ff"; - }; - layout = mkOption { - description = "which layout to use."; - type = types.enum ["dwindle" "master"]; - default = "dwindle"; - }; - noFocusFallback = mkOption { - description = "if true, will not fall back to the next available window when moving focus in a direction where no window was found"; - type = types.bool; - default = false; - }; - resizeOnBorder = mkOption { - description = "enables resizing windows by clicking and dragging on borders and gaps"; - type = types.bool; - default = false; - }; - extendBorderGrabArea = mkOption { - description = "extends the area around the border where you can click and drag on, only used when `general:resizeOnBorder` is on."; - type = types.int; - default = 15; - }; - hoverIconOnBorder = mkOption { - description = "show a cursor icon when hovering over borders, only used when `general:resizeOnBorder` is on."; - type = types.bool; - default = true; - }; - allowTearing = mkOption { - description = "master switch for allowing tearing to occur. See [the Tearing page](../Tearing)."; - type = types.bool; - default = false; - }; - resizeCorner = mkOption { - description = "force floating windows to use a specific corner when being resized (1-4 going clockwise from top left, 0 to disable)"; - type = types.int; - default = 0; - }; - modalParentBlocking = mkOption { - description = "whether parent windows of modals will be interactive"; - type = types.bool; - default = true; - }; - locale = mkOption { - description = "overrides the system locale (e.g. enuS, es)"; - type = types.str; - default = ""; - }; - }; - - general.snap = { - enabled = mkOption { - description = "enable snapping for floating windows"; - type = types.bool; - default = false; - }; - windowGap = mkOption { - description = "minimum gap in pixels between windows before snapping"; - type = types.int; - default = 10; - }; - monitorGap = mkOption { - description = "minimum gap in pixels between window and monitor edges before snapping"; - type = types.int; - default = 10; - }; - borderOverlap = mkOption { - description = "if true, windows snap such that only one border's worth of space is between them"; - type = types.bool; - default = false; - }; - respectGaps = mkOption { - description = "if true, snapping will respect gaps between windows(set in general:gapsIn)"; - type = types.bool; - default = false; - }; - }; - - decoration = { - rounding = mkOption { - description = "rounded corners' radius (in layout px)"; - type = types.int; - default = 0; - }; - roundingPower = mkOption { - description = "adjusts the curve used for rounding corners, larger is smoother, 2.0 is a circle, 4.0 is a squircle, 1.0 is a triangular corner."; - type = types.numbers.between 1.0 10.0; - default = 2.0; - }; - activeOpacity = mkOption { - description = "opacity of active windows."; - type = types.numbers.between 0.0 1.0; - default = 1.0; - }; - inactiveOpacity = mkOption { - description = "opacity of inactive windows."; - type = types.numbers.between 0.0 1.0; - default = 1.0; - }; - fullscreenOpacity = mkOption { - description = "opacity of fullscreen windows."; - type = types.numbers.between 0.0 1.0; - default = 1.0; - }; - dimModal = mkOption { - description = "enables dimming of parents of modal windows"; - type = types.bool; - default = true; - }; - dimInactive = mkOption { - description = "enables dimming of inactive windows"; - type = types.bool; - default = false; - }; - dimStrength = mkOption { - description = "how much inactive windows should be dimmed"; - type = types.numbers.between 0.0 1.0; - default = 0.5; - }; - dimSpecial = mkOption { - description = "how much to dim the rest of the screen by when a special workspace is open."; - type = types.numbers.between 0.0 1.0; - default = 0.2; - }; - dimAround = mkOption { - description = "how much the `dimAround` window rule should dim by."; - type = types.numbers.between 0.0 1.0; - default = 0.4; - }; - screenShader = mkOption { - description = "a path to a custom shader to be applied at the end of rendering. See `examples/screenShader.frag` for an example."; - type = types.str; - default = ""; - }; - borderPartOfWindow = mkOption { - description = "whether the window border should be a part of the window"; - type = types.bool; - default = true; - }; - }; - - decoration.blur = { - enabled = mkOption { - description = "enable kawase window background blur"; - type = types.bool; - default = true; - }; - size = mkOption { - description = "blur size (distance)"; - type = types.int; - default = 8; - }; - passes = mkOption { - description = "the amount of passes to perform"; - type = types.int; - default = 1; - }; - ignoreOpacity = mkOption { - description = "make the blur layer ignore the opacity of the window"; - type = types.bool; - default = true; - }; - newOptimizations = mkOption { - description = "whether to enable further optimizations to the blur. Recommended to leave on, as it will massively improve performance."; - type = types.bool; - default = true; - }; - xray = mkOption { - description = "if enabled, floating windows will ignore tiled windows in their blur. Only available if newOptimizations is true. Will reduce overhead on floating blur significantly."; - type = types.bool; - default = false; - }; - noise = mkOption { - description = "how much noise to apply."; - type = types.numbers.between 0.0 1.0; - default = 0.0117; - }; - contrast = mkOption { - description = "contrast modulation for blur."; - type = types.numbers.between 0.0 2.0; - default = 0.8916; - }; - brightness = mkOption { - description = "brightness modulation for blur."; - type = types.numbers.between 0.0 2.0; - default = 0.8172; - }; - vibrancy = mkOption { - description = "Increase saturation of blurred colors."; - type = types.numbers.between 0.0 1.0; - default = 0.1696; - }; - vibrancyDarkness = mkOption { - description = "How strong the effect of `vibrancy` is on dark areas."; - type = types.numbers.between 0.0 1.0; - default = 0.0; - }; - special = mkOption { - description = "whether to blur behind the special workspace (note: expensive)"; - type = types.bool; - default = false; - }; - popups = mkOption { - description = "whether to blur popups (e.g. right-click menus)"; - type = types.bool; - default = false; - }; - popupsIgnorealpha = mkOption { - description = "works like ignoreAlpha in layer rules. If pixel opacity is below set value, will not blur."; - type = types.numbers.between 0.0 1.0; - default = 0.2; - }; - inputMethods = mkOption { - description = "whether to blur input methods (e.g. fcitx5)"; - type = types.bool; - default = false; - }; - inputMethodsIgnorealpha = mkOption { - description = "works like ignoreAlpha in layer rules. If pixel opacity is below set value, will not blur."; - type = types.numbers.between 0.0 1.0; - default = 0.2; - }; - }; - - decoration.shadow = { - enabled = mkOption { - description = "enable drop shadows on windows"; - type = types.bool; - default = true; - }; - range = mkOption { - description = "Shadow range ('size') in layout px"; - type = types.int; - default = 4; - }; - renderPower = mkOption { - description = "in what power to render the falloff (more power, the faster the falloff)"; - type = types.ints.between 1 4; - default = 3; - }; - sharp = mkOption { - description = "if enabled, will make the shadows sharp, akin to an infinite render power"; - type = types.bool; - default = false; - }; - ignoreWindow = mkOption { - description = "if true, the shadow will not be rendered behind the window itself, only around it."; - type = types.bool; - default = true; - }; - color = mkOption { - description = "shadow's color. Alpha dictates shadow's opacity."; - type = types.str; - default = "0xee1a1a1a"; - }; - colorInactive = mkOption { - description = "inactive shadow color. (if not set, will fall back to color)"; - type = types.str; - default = "0xee1a1a1a"; - }; - offset = mkOption { - description = "shadow's rendering offset."; - type = vec2; - default = { - x = 0; - y = 0; - }; - }; - scale = mkOption { - description = "shadow's scale."; - type = types.numbers.between 0.0 1.0; - default = 1.0; - }; - }; - - animations = { - enabled = mkOption { - description = "enable animations"; - type = types.bool; - default = true; - }; - workspaceWraparound = mkOption { - description = "enable workspace wraparound, causing directional workspace animations to animate as if the first and last workspaces were adjacent"; - type = types.bool; - default = false; - }; - }; - - input = { - kbModel = mkOption { - description = "Appropriate XKB keymap parameter. See the note below."; - type = types.str; - default = ""; - }; - kbLayout = mkOption { - description = "Appropriate XKB keymap parameter"; - type = types.str; - default = "us"; - }; - kbVariant = mkOption { - description = "Appropriate XKB keymap parameter"; - type = types.str; - default = ""; - }; - kbOptions = mkOption { - description = "Appropriate XKB keymap parameter"; - type = types.str; - default = ""; - }; - kbRules = mkOption { - description = "Appropriate XKB keymap parameter"; - type = types.str; - default = ""; - }; - kbFile = mkOption { - description = "If you prefer, you can use a path to your custom .xkb file."; - type = types.str; - default = ""; - }; - numlockByDefault = mkOption { - description = "Engage numlock by default."; - type = types.bool; - default = false; - }; - resolveBindsBySym = mkOption { - description = "Determines how keybinds act when multiple layouts are used. If false, keybinds will always act as if the first specified layout is active. If true, keybinds specified by symbols are activated when you type the respective symbol with the current layout."; - type = types.bool; - default = false; - }; - repeatRate = mkOption { - description = "The repeat rate for held-down keys, in repeats per second."; - type = types.int; - default = 25; - }; - repeatDelay = mkOption { - description = "Delay before a held-down key is repeated, in milliseconds."; - type = types.int; - default = 600; - }; - sensitivity = mkOption { - description = "Sets the mouse input sensitivity."; - type = types.numbers.between (-1.0) 1.0; - default = 0.0; - }; - accelProfile = mkOption { - description = "Sets the cursor acceleration profile."; - type = types.enum ["" "adaptive" "flat"]; - default = ""; - }; - forceNoAccel = mkOption { - description = "Force no cursor acceleration. This bypasses most of your pointer settings to get as raw of a signal as possible. **Enabling this is not recommended due to potential cursor desynchronization.**"; - type = types.bool; - default = false; - }; - rotation = mkOption { - description = "Sets the rotation of a device in degrees clockwise off the logical neutral position. Value is clamped to the range 0 to 359."; - type = types.int; - default = 0; - }; - leftHanded = mkOption { - description = "Switches RMB and LMB"; - type = types.bool; - default = false; - }; - scrollPoints = mkOption { - description = "Sets the scroll acceleration profile, when `accelProfile` is set to `custom`. Has to be in the form ` `. Leave empty to have a flat scroll curve."; - type = types.str; - default = ""; - }; - scrollMethod = mkOption { - description = "Sets the scroll method. Can be one of `2fg` (2 fingers), `edge`, `onButtonDown`, `noScroll`. [libinput#scrolling](https://wayland.freedesktop.org/libinput/doc/latest/scrolling.html) [2fg/edge/onButtonDown/noScroll]"; - type = types.enum ["" "2fg" "edge" "onButtonDown" "noScroll"]; - default = ""; - }; - scrollButton = mkOption { - description = "Sets the scroll button. Has to be an int, cannot be a string. Check `wev` if you have any doubts regarding the ID. 0 means default."; - type = types.int; - default = 0; - }; - scrollButtonLock = mkOption { - description = "If the scroll button lock is enabled, the button does not need to be held down. Pressing and releasing the button toggles the button lock, which logically holds the button down or releases it. While the button is logically held down, motion events are converted to scroll events."; - type = types.bool; - default = false; - }; - scrollFactor = mkOption { - description = "Multiplier added to scroll movement for external mice. Note that there is a separate setting for [touchpad scrollFactor](#touchpad). "; - type = types.float; - default = 1.0; - }; - naturalScroll = mkOption { - description = "Inverts scrolling direction. When enabled, scrolling moves content directly, rather than manipulating a scrollbar."; - type = types.bool; - default = false; - }; - followMouse = mkOption { - description = "Specify if and how cursor movement should affect window focus. See the note below."; - type = types.ints.between 0 3; - default = 1; - }; - followMouseThreshold = mkOption { - description = "The smallest distance in logical pixels the mouse needs to travel for the window under it to get focused. Works only with followMouse = 1."; - type = types.float; - default = 0.0; - }; - focusOnClose = mkOption { - description = "Controls the window focus behavior when a window is closed. When set to 0, focus will shift to the next window candidate. When set to 1, focus will shift to the window under the cursor."; - type = types.ints.between 0 1; - default = 0; - }; - mouseRefocus = mkOption { - description = "If disabled, mouse focus won't switch to the hovered window unless the mouse crosses a window boundary when `followMouse=1`."; - type = types.bool; - default = true; - }; - floatSwitchOverrideFocus = mkOption { - description = "If enabled (1 or 2), focus will change to the window under the cursor when changing from tiled-to-floating and vice versa. If 2, focus will also follow mouse on float-to-float switches."; - type = types.int; - default = 1; - }; - specialFallthrough = mkOption { - description = "if enabled, having only floating windows in the special workspace will not block focusing windows in the regular workspace."; - type = types.bool; - default = false; - }; - offWindowAxisEvents = mkOption { - description = "Handles axis events around (gaps/border for tiled, dragarea/border for floated) a focused window. `0` ignores axis events `1` sends out-of-bound coordinates `2` fakes pointer coordinates to the closest point inside the window `3` warps the cursor to the closest point inside the window"; - type = types.ints.between 0 3; - default = 1; - }; - emulateDiscreteScroll = mkOption { - description = "Emulates discrete scrolling from high resolution scrolling events. `0` disables it, `1` enables handling of non-standard events only, and `2` force enables all scroll wheel events to be handled"; - type = types.ints.between 0 2; - default = 1; - }; - }; - - input.touchpad = { - disableWhileTyping = mkOption { - description = "Disable the touchpad while typing."; - type = types.bool; - default = true; - }; - naturalScroll = mkOption { - description = "Inverts scrolling direction. When enabled, scrolling moves content directly, rather than manipulating a scrollbar."; - type = types.bool; - default = false; - }; - scrollFactor = mkOption { - description = "Multiplier applied to the amount of scroll movement."; - type = types.float; - default = 1.0; - }; - middleButtonEmulation = mkOption { - description = "Sending LMB and RMB simultaneously will be interpreted as a middle click. This disables any touchpad area that would normally send a middle click based on location."; - type = types.bool; - default = false; - }; - tapButtonMap = mkOption { - description = "Sets the tap button mapping for touchpad button emulation."; - type = types.enum ["lrm" "lmr"]; - default = "lrm"; - }; - clickfingerBehavior = mkOption { - description = "Button presses with 1, 2, or 3 fingers will be mapped to LMB, RMB, and MMB respectively. This disables interpretation of clicks based on location on the touchpad."; - type = types.bool; - default = false; - }; - tapToClick = mkOption { - description = "Tapping on the touchpad with 1, 2, or 3 fingers will send LMB, RMB, and MMB respectively."; - type = types.bool; - default = true; - }; - dragLock = mkOption { - description = "When enabled, lifting the finger off while dragging will not drop the dragged item."; - type = types.ints.between 0 2; - default = 0; - }; - tapAndDrag = mkOption { - description = "Sets the tap and drag mode for the touchpad"; - type = types.bool; - default = true; - }; - flipX = mkOption { - description = "inverts the horizontal movement of the touchpad"; - type = types.bool; - default = false; - }; - flipY = mkOption { - description = "inverts the vertical movement of the touchpad"; - type = types.bool; - default = false; - }; - drag3fg = mkOption { - description = "enables three finger drag, 0 -> disabled, 1 -> 3 fingers, 2 -> 4 fingers"; - type = types.ints.between 0 2; - default = 0; - }; - }; - - input.touchdevice = { - transform = mkOption { - description = "Transform the input from touchdevices. The possible transformations are the same as [those of the monitors](../Monitors/#rotating). `-1` means it's unset."; - type = types.ints.between (-1) 7; - default = -1; - }; - output = mkOption { - description = "The monitor to bind touch devices. The default is auto-detection. To stop auto-detection, use an empty string or the '[[Empty]]' value."; - type = types.str; - default = "[[Auto]]"; - }; - enabled = mkOption { - description = "Whether input is enabled for touch devices."; - type = types.bool; - default = true; - }; - }; - - input.virtualkeyboard = { - shareStates = mkOption { - description = "Unify key down states and modifier states with other keyboards. 0 -> no, 1 -> yes, 2 -> yes unless IME client"; - type = types.ints.between 0 2; - default = 2; - }; - releasePressedOnClose = mkOption { - description = "Release all pressed keys by virtual keyboard on close."; - type = types.bool; - default = false; - }; - }; - - input.tablet = { - transform = mkOption { - description = "transform the input from tablets. The possible transformations are the same as [those of the monitors](../Monitors/#rotating). `-1` means it's unset."; - type = types.ints.between (-1) 7; - default = -1; - }; - output = mkOption { - description = "the monitor to bind tablets. Can be `current` or a monitor name. Leave empty to map across all monitors."; - type = types.str; - default = ""; - }; - regionPosition = mkOption { - description = "position of the mapped region in monitor layout relative to the top left corner of the bound monitor or all monitors."; - type = vec2; - default = { - x = 0; - y = 0; - }; - }; - absoluteRegionPosition = mkOption { - description = "whether to treat the `regionPosition` as an absolute position in monitor layout. Only applies when `output` is empty."; - type = types.bool; - default = false; - }; - regionSize = mkOption { - description = "size of the mapped region. When this variable is set, tablet input will be mapped to the region. [0, 0] or invalid size means unset."; - type = vec2; - default = { - x = 0; - y = 0; - }; - }; - relativeInput = mkOption { - description = "whether the input should be relative"; - type = types.bool; - default = false; - }; - leftHanded = mkOption { - description = "if enabled, the tablet will be rotated 180 degrees"; - type = types.bool; - default = false; - }; - activeAreaSize = mkOption { - description = "size of tablet's active area in mm"; - type = vec2; - default = { - x = 0; - y = 0; - }; - }; - activeAreaPosition = mkOption { - description = "position of the active area in mm"; - type = vec2; - default = { - x = 0; - y = 0; - }; - }; - }; - - gestures = { - workspaceSwipeDistance = mkOption { - description = "in px, the distance of the touchpad gesture"; - type = types.int; - default = 300; - }; - workspaceSwipeTouch = mkOption { - description = "enable workspace swiping from the edge of a touchscreen"; - type = types.bool; - default = false; - }; - workspaceSwipeInvert = mkOption { - description = "invert the direction (touchpad only)"; - type = types.bool; - default = true; - }; - workspaceSwipeTouchInvert = mkOption { - description = "invert the direction (touchscreen only)"; - type = types.bool; - default = false; - }; - workspaceSwipeMinSpeedToForce = mkOption { - description = "minimum speed in px per timepoint to force the change ignoring `cancelRatio`. Setting to `0` will disable this mechanic."; - type = types.int; - default = 30; - }; - workspaceSwipeCancelRatio = mkOption { - description = "how much the swipe has to proceed in order to commence it. (0.7 -> if > 0.7 * distance, switch, if less, revert)"; - type = types.numbers.between 0.0 1.0; - default = 0.5; - }; - workspaceSwipeCreateNew = mkOption { - description = "whether a swipe right on the last workspace should create a new one."; - type = types.bool; - default = true; - }; - workspaceSwipeDirectionLock = mkOption { - description = "if enabled, switching direction will be locked when you swipe past the `directionLockThreshold` (touchpad only)."; - type = types.bool; - default = true; - }; - workspaceSwipeDirectionLockThreshold = mkOption { - description = "in px, the distance to swipe before direction lock activates (touchpad only)."; - type = types.int; - default = 10; - }; - workspaceSwipeForever = mkOption { - description = "if enabled, swiping will not clamp at the neighboring workspaces but continue to the further ones."; - type = types.bool; - default = false; - }; - workspaceSwipeUseR = mkOption { - description = "if enabled, swiping will use the `r` prefix instead of the `m` prefix for finding workspaces."; - type = types.bool; - default = false; - }; - closeMaxTimeout = mkOption { - description = "the timeout for a window to close when using a 1:1 gesture, in ms"; - type = types.int; - default = 1000; - }; - }; - - group = { - autoGroup = mkOption { - description = "whether new windows will be automatically grouped into the focused unlocked group. Note: if you want to disable autoGroup only for specific windows, use the 'group-barred' instead."; - type = types.bool; - default = true; - }; - insertAfterCurrent = mkOption { - description = "whether new windows in a group spawn after current or at group tail"; - type = types.bool; - default = true; - }; - focusRemovedWindow = mkOption { - description = "whether Hyprland should focus on the window that has just been moved out of the group"; - type = types.bool; - default = true; - }; - dragIntoGroup = mkOption { - description = "whether dragging a window into a unlocked group will merge them. Options: 0 (disabled), 1 (enabled), 2 (only when dragging into the groupbar)"; - type = types.ints.between 0 2; - default = 1; - }; - mergeGroupsOnDrag = mkOption { - description = "whether window groups can be dragged into other groups"; - type = types.bool; - default = true; - }; - mergeGroupsOnGroupbar = mkOption { - description = "whether one group will be merged with another when dragged into its groupbar"; - type = types.bool; - default = true; - }; - mergeFloatedIntoTiledOnGroupbar = mkOption { - description = "whether dragging a floating window into a tiled window groupbar will merge them"; - type = types.bool; - default = false; - }; - groupOnMovetoworkspace = mkOption { - description = "whether using movetoworkspace[silent] will merge the window into the workspace's solitary unlocked group"; - type = types.bool; - default = false; - }; - col.borderActive = mkOption { - description = "active group border color"; - type = types.str; - default = "0x66ffff00"; - }; - col.borderInactive = mkOption { - description = "inactive (out of focus) group border color"; - type = types.str; - default = "0x66777700"; - }; - col.borderLockedActive = mkOption { - description = "active locked group border color"; - type = types.str; - default = "0x66ff5500"; - }; - col.borderLockedInactive = mkOption { - description = "inactive locked group border color"; - type = types.str; - default = "0x66775500"; - }; - }; - - group.groupbar = { - enabled = mkOption { - description = "enables groupbars"; - type = types.bool; - default = true; - }; - fontFamily = mkOption { - description = "font used to display groupbar titles, use `misc:fontFamily` if not specified"; - type = types.str; - default = ""; - }; - fontSize = mkOption { - description = "font size of groupbar title"; - type = types.int; - default = 8; - }; - fontWeightActive = mkOption { - description = "font weight of active groupbar title"; - type = fontWeight; - default = "normal"; - }; - fontWeightInactive = mkOption { - description = "font weight of inactive groupbar title"; - type = fontWeight; - default = "normal"; - }; - gradients = mkOption { - description = "enables gradients"; - type = types.bool; - default = false; - }; - height = mkOption { - description = "height of the groupbar"; - type = types.int; - default = 14; - }; - indicatorGap = mkOption { - description = "height of gap between groupbar indicator and title"; - type = types.int; - default = 0; - }; - indicatorHeight = mkOption { - description = "height of the groupbar indicator"; - type = types.int; - default = 3; - }; - stacked = mkOption { - description = "render the groupbar as a vertical stack"; - type = types.bool; - default = false; - }; - priority = mkOption { - description = "sets the decoration priority for groupbars"; - type = types.int; - default = 3; - }; - renderTitles = mkOption { - description = "whether to render titles in the group bar decoration"; - type = types.bool; - default = true; - }; - textOffset = mkOption { - description = "adjust vertical position for titles"; - type = types.int; - default = 0; - }; - scrolling = mkOption { - description = "whether scrolling in the groupbar changes group active window"; - type = types.bool; - default = true; - }; - rounding = mkOption { - description = "how much to round the indicator"; - type = types.int; - default = 1; - }; - roundingPower = mkOption { - description = " adjusts the curve used for rounding broupbar corners, larger is smoother, 2.0 is a circle, 4.0 is a squircle, 1.0 is a triangular corner."; - type = types.numbers.between 0.0 10.0; - default = 2.0; - }; - gradientRounding = mkOption { - description = "how much to round the gradients"; - type = types.int; - default = 2; - }; - gradientRoundingPower = mkOption { - description = "adjusts the curve used for rounding gradient corners, larger is smoother, 2.0 is a circle, 4.0 is a squircle, 1.0 is a triangular corner."; - type = types.numbers.between 0.0 10.0; - default = 2.0; - }; - roundOnlyEdges = mkOption { - description = "round only the indicator edges of the entire groupbar"; - type = types.bool; - default = true; - }; - gradientRoundOnlyEdges = mkOption { - description = "round only the gradient edges of the entire groupbar"; - type = types.bool; - default = true; - }; - textColor = mkOption { - description = "color for window titles in the groupbar"; - type = types.str; - default = "0xffffffff"; - }; - textColorInactive = mkOption { - description = "color for inactive windows' titles in the groupbar (if unset, defaults to textColor)"; - type = types.str; - default = "unset"; - }; # TODO unset? - textColorLockedActive = mkOption { - description = "color for the active window's title in a locked group (if unset, defaults to textColor)"; - type = types.str; - default = "unset"; - }; # TODO unset? - textColorLockedInactive = mkOption { - description = "color for inactive windows' titles in locked groups (if unset, defaults to textColorInactive)"; - type = types.str; - default = "unset"; - }; # TODO unset? - col.active = mkOption { - description = "active group bar background color"; - type = types.str; - default = "0x66ffff00"; - }; - col.inactive = mkOption { - description = "inactive (out of focus) group bar background color"; - type = types.str; - default = "0x66777700"; - }; - col.lockedActive = mkOption { - description = "active locked group bar background color"; - type = types.str; - default = "0x66ff5500"; - }; - col.lockedInactive = mkOption { - description = "inactive locked group bar background color"; - type = types.str; - default = "0x66775500"; - }; - gapsIn = mkOption { - description = "gap size between gradients"; - type = types.int; - default = 2; - }; - gapsOut = mkOption { - description = "gap size between gradients and window"; - type = types.int; - default = 2; - }; - keepUpperGap = mkOption { - description = "add or remove upper gap"; - type = types.bool; - default = true; - }; - blur = mkOption { - description = "applies blur to the groupbar indicators and gradients"; - type = types.bool; - default = false; - }; - }; - - misc = { - disableHyprlandLogo = mkOption { - description = "disables the random Hyprland logo / anime girl background. :("; - type = types.bool; - default = false; - }; - disableSplashRendering = mkOption { - description = "disables the Hyprland splash rendering. (requires a monitor reload to take effect)"; - type = types.bool; - default = false; - }; - disableScaleNotification = mkOption { - description = "disables notification popup when a monitor fails to set a suitable scale"; - type = types.bool; - default = false; - }; - col.splash = mkOption { - description = "Changes the color of the splash text (requires a monitor reload to take effect)."; - type = types.str; - default = "0xffffffff"; - }; - fontFamily = mkOption { - description = "Set the global default font to render the text including debug fps/notification, config error messages and etc., selected from system fonts."; - type = types.str; - default = "Sans"; - }; - splashFontFamily = mkOption { - description = "Changes the font used to render the splash text, selected from system fonts (requires a monitor reload to take effect)."; - type = types.str; - default = ""; - }; - forceDefaultWallpaper = mkOption { - description = "Enforce any of the 3 default wallpapers. Setting this to `0` or `1` disables the anime background. `-1` means 'random'."; - type = types.ints.between (-1) 2; - default = -1; - }; - vfr = mkOption { - description = "controls the VFR status of Hyprland. Heavily recommended to leave enabled to conserve resources."; - type = types.bool; - default = true; - }; - vrr = mkOption { - description = "controls the VRR (Adaptive Sync) of your monitors. 0 - off, 1 - on, 2 - fullscreen only, 3 - fullscreen with `video` or `game` content type"; - type = types.ints.between 0 3; - default = 0; - }; - mouseMoveEnablesDPMS = mkOption { - description = "If DPMS is set to off, wake up the monitors if the mouse moves."; - type = types.bool; - default = false; - }; - keyPressEnablesDPMS = mkOption { - description = "If DPMS is set to off, wake up the monitors if a key is pressed."; - type = types.bool; - default = false; - }; - nameVkAfterProc = mkOption { - description = "Name virtual keyboards after the processes that create them. E.g. /usr/bin/fcitx5 will have hl-virtual-keyboard-fcitx5."; - type = types.bool; - default = true; - }; - alwaysFollowOnDnd = mkOption { - description = "Will make mouse focus follow the mouse when drag and dropping. Recommended to leave it enabled, especially for people using focus follows mouse at 0."; - type = types.bool; - default = true; - }; - layersHogKeyboardFocus = mkOption { - description = "If true, will make keyboard-interactive layers keep their focus on mouse move (e.g. wofi, bemenu)"; - type = types.bool; - default = true; - }; - animateManualResizes = mkOption { - description = "If true, will animate manual window resizes/moves"; - type = types.bool; - default = false; - }; - animateMouseWindowdragging = mkOption { - description = "If true, will animate windows being dragged by mouse, note that this can cause weird behavior on some curves"; - type = types.bool; - default = false; - }; - disableAutoreload = mkOption { - description = "If true, the config will not reload automatically on save, and instead needs to be reloaded with `hyprctl reload`. Might save on battery."; - type = types.bool; - default = false; - }; - enableSwallow = mkOption { - description = "Enable window swallowing"; - type = types.bool; - default = false; - }; - swallowRegex = mkOption { - description = "The Class regex to be used for windows that should be swallowed (usually, a terminal)."; - type = types.str; - default = ""; - }; - swallowExceptionRegex = mkOption { - description = "The Title regex to be used for windows that should Not be swallowed by the windows specified in swallowRegex (e.g. wev). The regex is matched against the parent (e.g. Kitty) window's title on the assumption that it changes to whatever process it's running."; - type = types.str; - default = ""; - }; - focusOnActivate = mkOption { - description = "Whether Hyprland should focus an app that requests to be focused (an `activate` request)"; - type = types.bool; - default = false; - }; - mouseMoveFocusesMonitor = mkOption { - description = "Whether mouse moving into a different monitor should focus it"; - type = types.bool; - default = true; - }; - allowSessionLockRestore = mkOption { - description = "if true, will allow you to restart a lockscreen app in case it crashes"; - type = types.bool; - default = false; - }; - sessionLockXray = mkOption { - description = "if true, keep rendering workspaces below your lockscreen"; - type = types.bool; - default = false; - }; - backgroundColor = mkOption { - description = "change the background color. (requires enabled `disableHyprlandLogo`)"; - type = types.str; - default = "0x111111"; - }; - closeSpecialOnEmpty = mkOption { - description = "close the special workspace if the last window is removed"; - type = types.bool; - default = true; - }; - newWindowTakesOverFullscreen = mkOption { - description = "if there is a fullscreen or maximized window, decide whether a tiled window requested to focus should replace it, stay behind or disable the fullscreen/maximized state. 0 - ignore focus request (keep focus on fullscreen window), 1 - takes over, 2 - unfullscreen/unmaximize [0/1/2]"; - type = types.ints.between 0 2; - default = 2; - }; - exitWindowRetainsFullscreen = mkOption { - description = "if true, closing a fullscreen window makes the next focused window fullscreen"; - type = types.bool; - default = false; - }; - initialWorkspaceTracking = mkOption { - description = "if enabled, windows will open on the workspace they were invoked on. 0 - disabled, 1 - single-shot, 2 - persistent (all children too)"; - type = types.ints.between 0 2; - default = 1; - }; - middleClickPaste = mkOption { - description = "whether to enable middle-click-paste (aka primary selection)"; - type = types.bool; - default = true; - }; - renderUnfocusedFps = mkOption { - description = "the maximum limit for renderUnfocused windows' fps in the background (see also [Window-Rules](../Window-Rules/#dynamic-effects) - `renderUnfocused`)"; - type = types.int; - default = 15; - }; - disableXdgEnvChecks = mkOption { - description = "disable the warning if XDG environment is externally managed"; - type = types.bool; - default = false; - }; - disableHyprlandGuiUtilsCheck = mkOption { - description = "disable the warning if hyprland-qtutils is not installed"; - type = types.bool; - default = false; - }; - lockdeadScreenDelay = mkOption { - description = "delay after which the 'lockdead' screen will appear in case a lockscreen app fails to cover all the outputs (5 seconds max)"; - type = types.int; - default = 1000; - }; - enableAnrDialog = mkOption { - description = "whether to enable the ANR (app not responding) dialog when your apps hang"; - type = types.bool; - default = true; - }; - anrMissedPings = mkOption { - description = "number of missed pings before showing the ANR dialog"; - type = types.int; - default = 5; - }; - sizeLimitsTiled = mkOption { - description = "whether to apply minSize and maxSize rules to tiled windows"; - type = types.bool; - default = false; - }; - }; - - binds = { - passMouseWhenBound = mkOption { - description = "if disabled, will not pass the mouse events to apps / dragging windows around if a keybind has been triggered."; - type = types.bool; - default = false; - }; - scrollEventDelay = mkOption { - description = "in ms, how many ms to wait after a scroll event to allow passing another one for the binds."; - type = types.int; - default = 300; - }; - workspaceBackAndForth = mkOption { - description = "If enabled, an attempt to switch to the currently focused workspace will instead switch to the previous workspace. Akin to i3's AutoBackAndForth."; - type = types.bool; - default = false; - }; - hideSpecialOnWorkspaceChange = mkOption { - description = "If enabled, changing the active workspace (including to itself) will hide the special workspace on the monitor where the newly active workspace resides."; - type = types.bool; - default = false; - }; - allowWorkspaceCycles = mkOption { - description = "If enabled, workspaces don't forget their previous workspace, so cycles can be created by switching to the first workspace in a sequence, then endlessly going to the previous workspace."; - type = types.bool; - default = false; - }; - workspaceCenterOn = mkOption { - description = "Whether switching workspaces should center the cursor on the workspace (0) or on the last active window for that workspace (1)"; - type = types.ints.between 0 1; - default = 0; - }; - focusPreferredMethod = mkOption { - description = "sets the preferred focus finding method when using `focuswindow`/`movewindow`/etc with a direction. 0 - history (recent have priority), 1 - length (longer shared edges have priority)"; - type = types.int; - default = 0; - }; - ignoreGroupLock = mkOption { - description = "If enabled, dispatchers like `moveintogroup`, `moveoutofgroup` and `movewindoworgroup` will ignore lock per group."; - type = types.bool; - default = false; - }; - movefocusCyclesFullscreen = mkOption { - description = "If enabled, when on a fullscreen window, `movefocus` will cycle fullscreen, if not, it will move the focus in a direction."; - type = types.bool; - default = false; - }; - movefocusCyclesGroupfirst = mkOption { - description = "If enabled, when in a grouped window, movefocus will cycle windows in the groups first, then at each ends of tabs, it'll move on to other windows/groups"; - type = types.bool; - default = false; - }; - disableKeybindGrabbing = mkOption { - description = "If enabled, apps that request keybinds to be disabled (e.g. VMs) will not be able to do so."; - type = types.bool; - default = false; - }; - windowDirectionMonitorFallback = mkOption { - description = "If enabled, moving a window or focus over the edge of a monitor with a direction will move it to the next monitor in that direction."; - type = types.bool; - default = true; - }; - allowPinFullscreen = mkOption { - description = "If enabled, Allow fullscreen to pinned windows, and restore their pinned status afterwards"; - type = types.bool; - default = false; - }; - dragThreshold = mkOption { - description = "Movement threshold in pixels for window dragging and c/g bind flags. 0 to disable and grab on mousedown."; - type = types.int; - default = 0; - }; - }; - - xwayland = { - enabled = mkOption { - description = "allow running applications using X11"; - type = types.bool; - default = true; - }; - useNearestNeighbor = mkOption { - description = "uses the nearest neighbor filtering for xwayland apps, making them pixelated rather than blurry"; - type = types.bool; - default = true; - }; - forceZeroScaling = mkOption { - description = "forces a scale of 1 on xwayland windows on scaled displays."; - type = types.bool; - default = false; - }; - createAbstractSocket = mkOption { - description = "Create the [abstract Unix domain socket](../XWayland/#abstract-unix-domain-socket) for XWayland connections. (XWayland restart is required for changes to take effect; Linux only)"; - type = types.bool; - default = false; - }; - }; - - opengl = { - nvidiaAntiFlicker = mkOption { - description = "reduces flickering on nvidia at the cost of possible frame drops on lower-end GPUs. On non-nvidia, this is ignored."; - type = types.bool; - default = true; - }; - }; - - render = { - directScanout = mkOption { - description = "Enables direct scanout. Direct scanout attempts to reduce lag when there is only one fullscreen application on a screen (e.g. game). It is also recommended to set this to false if the fullscreen application shows graphical glitches. 0 - off, 1 - on, 2 - auto (on with content type 'game')"; - type = types.ints.between 0 2; - default = 0; - }; - expandUndersizedTextures = mkOption { - description = "Whether to expand undersized textures along the edge, or rather stretch the entire texture."; - type = types.bool; - default = true; - }; - xpMode = mkOption { - description = "Disables back buffer and bottom layer rendering."; - type = types.bool; - default = false; - }; - ctmAnimation = mkOption { - description = "Whether to enable a fade animation for CTM changes (hyprsunset). 2 means 'auto' which disables them on Nvidia."; - type = types.int; - default = 2; - }; - cmFsPassthrough = mkOption { - description = "Passthrough color settings for fullscreen apps when possible. 0 - off, 1 - always, 2 - hdr only"; - type = types.int; - default = 2; - }; - cmEnabled = mkOption { - description = "Whether the color management pipeline should be enabled or not (requires a restart of Hyprland to fully take effect)"; - type = types.bool; - default = true; - }; - sendContentType = mkOption { - description = "Report content type to allow monitor profile autoswitch (may result in a black screen during the switch)"; - type = types.bool; - default = true; - }; - cmAutoHdr = mkOption { - description = "Auto-switch to HDR in fullscreen when needed. 0 - off, 1 - switch to `cm, hdr`, 2 - switch to `cm, hdredid`"; - type = types.ints.between 0 2; - default = 1; - }; - newRenderScheduling = mkOption { - description = "Automatically uses triple buffering when needed, improves FPS on underpowered devices."; - type = types.bool; - default = false; - }; - nonShaderCm = mkOption { - description = "Enable CM without shader. 0 - disable, 1 - whenever possible, 2 - DS and passthrough only, 3 - disable and ignore CM issues"; - type = types.ints.between 0 3; - default = 3; - }; - cmSdrEotf = mkOption { - description = "Default transfer function for displaying SDR apps. 0 - Treat unspecified as sRGB, 1 - Treat unspecified as Gamma 2.2, 2 - Treat unspecified and sRGB as Gamma 2.2"; - type = types.ints.between 0 2; - default = 0; - }; - }; - - cursor = { - invisible = mkOption { - description = "don't render cursors"; - type = types.bool; - default = false; - }; - syncGsettingsTheme = mkOption { - description = "sync xcursor theme with gsettings, it applies cursor-theme and cursor-size on theme load to gsettings making most CSD gtk based clients use same xcursor theme and size."; - type = types.bool; - default = true; - }; - noHardwareCursors = mkOption { - description = "disables hardware cursors. 0 - use hw cursors if possible, 1 - don't use hw cursors, 2 - auto (disable when tearing)"; - type = types.ints.between 0 2; - default = 2; - }; - noBreakFsVrr = mkOption { - description = "disables scheduling new frames on cursor movement for fullscreen apps with VRR enabled to avoid framerate spikes (may require noHardwareCursors = true) 0 - off, 1 - on, 2 - auto (on with content type 'game')"; - type = types.ints.between 0 2; - default = 2; - }; - minRefreshRate = mkOption { - description = "minimum refresh rate for cursor movement when `noBreakFsVrr` is active. Set to minimum supported refresh rate or higher"; - type = types.int; - default = 24; - }; - hotspotPadding = mkOption { - description = "the padding, in logical px, between screen edges and the cursor"; - type = types.int; - default = 1; - }; - inactiveTimeout = mkOption { - description = "in seconds, after how many seconds of cursor's inactivity to hide it. Set to `0` for never."; - type = types.number; - default = 0; - }; - noWarps = mkOption { - description = "if true, will not warp the cursor in many cases (focusing, keybinds, etc)"; - type = types.bool; - default = false; - }; - persistentWarps = mkOption { - description = "When a window is refocused, the cursor returns to its last position relative to that window, rather than to the centre."; - type = types.bool; - default = false; - }; - warpOnChangeWorkspace = mkOption { - description = "Move the cursor to the last focused window after changing the workspace. Options: 0 (Disabled), 1 (Enabled), 2 (Force - ignores cursor:noWarps option)"; - type = types.ints.between 0 2; - default = 0; - }; - warpOnToggleSpecial = mkOption { - description = "Move the cursor to the last focused window when toggling a special workspace. Options: 0 (Disabled), 1 (Enabled), 2 (Force - ignores cursor:noWarps option)"; - type = types.ints.between 0 2; - default = 0; - }; - defaultMonitor = mkOption { - description = "the name of a default monitor for the cursor to be set to on startup (see `hyprctl monitors` for names)"; - type = types.str; - default = ""; - }; - zoomFactor = mkOption { - description = "the factor to zoom by around the cursor. Like a magnifying glass. Minimum 1.0 (meaning no zoom)"; - type = types.addCheck types.number (x: x >= 1); - default = 1.0; - }; - zoomRigid = mkOption { - description = "whether the zoom should follow the cursor rigidly (cursor is always centered if it can be) or loosely"; - type = types.bool; - default = false; - }; - enableHyprcursor = mkOption { - description = "whether to enable hyprcursor support"; - type = types.bool; - default = true; - }; - hideOnKeyPress = mkOption { - description = "Hides the cursor when you press any key until the mouse is moved."; - type = types.bool; - default = false; - }; - hideOnTouch = mkOption { - description = "Hides the cursor when the last input was a touch input until a mouse input is done."; - type = types.bool; - default = true; - }; - useCpuBuffer = mkOption { - description = "Makes HW cursors use a CPU buffer. Required on Nvidia to have HW cursors. 0 - off, 1 - on, 2 - auto (nvidia only)"; - type = types.ints.between 0 2; - default = 2; - }; - warpBackAfterNonMouseInput = mkOption { - description = "Warp the cursor back to where it was after using a non-mouse input to move it, and then returning back to mouse."; - type = types.bool; - default = false; - }; - zoomDisableAa = mkOption { - description = "disable antialiasing when zooming, which means things will be pixelated instead of blurry"; - type = types.bool; - default = false; - }; - }; - - ecosystem = { - noUpdateNews = mkOption { - description = "disable the popup that shows up when you update hyprland to a new version."; - type = types.bool; - default = false; - }; - noDonationNag = mkOption { - description = "disable the popup that shows up twice a year encouraging to donate."; - type = types.bool; - default = false; - }; - enforcePermissions = mkOption { - description = "whether to enable [permission control](../Permissions)."; - type = types.bool; - default = false; - }; - }; - }; -} diff --git a/machines/artemis/modules.nix b/machines/artemis/modules.nix index 8436e12..5f94a9d 100644 --- a/machines/artemis/modules.nix +++ b/machines/artemis/modules.nix @@ -3,6 +3,21 @@ ../../modules ]; + nix-hyprland = { + monitors = { + bindWorkspaces = "interlaced"; + displays = [ + { + output = "eDP-1"; + x = 0; + y = 0; + bar = "top"; + scale = 1.175; # Idk why hyprland doesn't think 1.25 is invalid but whatever. + } + ]; + }; + }; + config.horseman = { dots.kitty.fontSize = 13; @@ -22,22 +37,7 @@ greeter.greetd.session = "Hyprland"; }; - wm.hyprland = { - enable = true; - - config = { - monitors.displays = [ - { - output = "eDP-1"; - x = 0; - y = 0; - bar = "top"; - scale = 1.175; # Idk why hyprland doesn't think 1.25 is invalid but whatever. - } - ]; - monitors.bindWorkspaces = "interlaced"; - }; - }; + wm.hyprland.enable = true; hardware = { audio.enable = true; diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index 92a10dc..fdce395 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -1,8 +1,30 @@ -{...}: { +{config, ...}: { imports = [ ../../modules ]; + config.nix-hyprland = { + username = config.horseman.username; + monitors = { + displays = [ + { + output = "DP-2"; + x = 0; + y = 0; + wallpaper = ../../misc/landscape.png; + } + { + output = "DP-3"; + x = -1440; + y = 0; + transform = 1; + wallpaper = ../../misc/portrait.png; + } + ]; + bindWorkspaces = "interlaced"; + }; + }; + config.horseman = { catppuccin.flavor = "mocha"; @@ -24,28 +46,6 @@ wm.hyprland = { enable = true; - - config = { - monitors = { - displays = [ - { - output = "DP-2"; - x = 0; - y = 0; - wallpaper = ../../misc/landscape.png; - } - { - output = "DP-3"; - x = -1440; - y = 0; - transform = 1; - wallpaper = ../../misc/portrait.png; - bar = "top"; - } - ]; - bindWorkspaces = "interlaced"; - }; - }; }; hardware = { diff --git a/modules/wm/hyprland/animations.nix b/modules/wm/hyprland/animations.nix index d09f256..18044ce 100644 --- a/modules/wm/hyprland/animations.nix +++ b/modules/wm/hyprland/animations.nix @@ -7,7 +7,7 @@ cfg = config.horseman.wm.hyprland; in { config = mkIf cfg.enable { - horseman.wm.hyprland.config = { + nix-hyprland = { animations = { enabled = true; beziers = [ @@ -51,103 +51,87 @@ in { animations = [ { name = "global"; - on = true; speed = 10.0; curve = "default"; } { name = "border"; - on = true; speed = 5.39; curve = "easeOutQuint"; } { name = "windows"; - on = true; speed = 4.79; curve = "easeOutQuint"; } { name = "windowsIn"; - on = true; speed = 4.1; curve = "easeOutQuint"; style = "popin 87%"; } { name = "windowsOut"; - on = true; speed = 1.49; curve = "linear"; style = "popin 87%"; } { name = "fadeIn"; - on = true; speed = 1.73; curve = "almostLinear"; } { name = "fadeOut"; - on = true; speed = 1.46; curve = "almostLinear"; } { name = "fade"; - on = true; speed = 3.03; curve = "quick"; } { name = "layers"; - on = true; speed = 3.81; curve = "easeOutQuint"; } { name = "layersIn"; - on = true; speed = 4.0; curve = "easeOutQuint"; style = "fade"; } { name = "layersOut"; - on = true; speed = 1.5; curve = "linear"; style = "fade"; } { name = "fadeLayersIn"; - on = true; speed = 1.79; curve = "almostLinear"; } { name = "fadeLayersOut"; - on = true; speed = 1.39; curve = "almostLinear"; } { name = "workspaces"; - on = true; speed = 1.94; curve = "almostLinear"; style = "fade"; } { name = "workspacesIn"; - on = true; speed = 1.21; curve = "almostLinear"; style = "fade"; } { name = "workspacesOut"; - on = true; speed = 1.94; curve = "almostLinear"; style = "fade"; diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index eab72ce..09962f5 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -45,7 +45,7 @@ in { horseman.hardware.keyd.enable = true; - horseman.wm.hyprland.config = { + nix-hyprland = { execOnce = [ "hypridle" "hyprpaper" @@ -54,8 +54,14 @@ in { ]; env = [ - "XCURSOR_SIZE,24" - "HYPRCURSOR_SIZE,24" + { + name = "XCURSOR_SIZE"; + value = "24"; + } + { + name = "HYPRCURSOR_SIZE"; + value = "24"; + } ]; windowrules = [ @@ -140,10 +146,10 @@ in { dragIntoGroup = 1; col = { - borderActive = config.horseman.wm.hyprland.config.general.col.activeBorder; # I don't wanna believe this can't be done better :( - borderInactive = config.horseman.wm.hyprland.config.general.col.inactiveBorder; - borderLockedActive = config.horseman.wm.hyprland.config.general.col.activeBorder; - borderLockedInactive = config.horseman.wm.hyprland.config.general.col.inactiveBorder; + borderActive = config.nix-hyprland.general.col.activeBorder; # I don't wanna believe this can't be done better :( + borderInactive = config.nix-hyprland.general.col.inactiveBorder; + borderLockedActive = config.nix-hyprland.general.col.activeBorder; + borderLockedInactive = config.nix-hyprland.general.col.inactiveBorder; }; groupbar = { @@ -164,7 +170,7 @@ in { }; monitors = { - defaultMonitor = true; + addDefault = true; }; sleep = { diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index 33a84dc..fcef0a8 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -7,506 +7,504 @@ cfg = config.horseman.wm.hyprland; in { config = mkIf cfg.enable { - horseman.wm.hyprland.config = { - keybindings = { - submaps = [ - { - name = "disable-all"; - enterBind = { - flags = ["o"]; - mods = ["SUPER"]; - key = "ESCAPE"; - }; - exitBind = { - flags = ["o"]; - mods = ["SUPER"]; - key = "ESCAPE"; - }; - - binds = []; - } - ]; - - binds = [ - { - flags = []; - mods = ["SUPER"]; - key = "SPACE"; - dispatcher = "exec"; - params = "pkill fuzzel || fuzzel"; - } - - { - flags = []; - mods = ["SUPER"]; - key = "B"; - dispatcher = "exec"; - params = "pkill waybar || waybar"; - } - - { - flags = []; - mods = ["SUPER"]; - key = "RETURN"; - dispatcher = "exec"; - params = "kitty"; - } - - { - flags = []; - mods = ["SUPER"]; - key = "Q"; - dispatcher = "killactive"; - params = ""; - } - - { - flags = []; - mods = []; - key = "F11"; - dispatcher = "fullscreen"; - params = ""; - } - { + nix-hyprland.keybindings = { + submaps = [ + { + name = "disable-all"; + enterBind = { flags = ["o"]; mods = ["SUPER"]; - key = "L"; - dispatcher = "exec"; - params = "hyprlock"; - } - { - flags = ["e"]; + key = "ESCAPE"; + }; + exitBind = { + flags = ["o"]; mods = ["SUPER"]; - key = "TAB"; - dispatcher = "changegroupactive"; - params = "f"; - } + key = "ESCAPE"; + }; - { - flags = ["e"]; - mods = ["SUPER" "SHIFT"]; - key = "TAB"; - dispatcher = "changegroupactive"; - params = "b"; - } - { - flags = []; - mods = ["SUPER"]; - key = "F"; - dispatcher = "togglefloating"; - params = ""; - } - { - flags = []; - mods = ["SUPER"]; - key = "T"; - dispatcher = "togglegroup"; - params = ""; - } + binds = []; + } + ]; - { - flags = []; - mods = ["SUPER"]; - key = "P"; - dispatcher = "pin"; - params = ""; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "S"; - dispatcher = "exec"; - params = "hyprshot -m region --clipboard-only"; - } + binds = [ + { + flags = []; + mods = ["SUPER"]; + key = "SPACE"; + dispatcher = "exec"; + params = "pkill fuzzel || fuzzel"; + } - { - flags = []; - mods = ["SUPER"]; - key = "H"; - dispatcher = "movefocus"; - params = "l"; - } - { - flags = []; - mods = ["SUPER"]; - key = "L"; - dispatcher = "movefocus"; - params = "r"; - } - { - flags = []; - mods = ["SUPER"]; - key = "K"; - dispatcher = "movefocus"; - params = "u"; - } - { - flags = []; - mods = ["SUPER"]; - key = "J"; - dispatcher = "movefocus"; - params = "d"; - } + { + flags = []; + mods = ["SUPER"]; + key = "B"; + dispatcher = "exec"; + params = "pkill waybar || waybar"; + } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "H"; - dispatcher = "movewindow"; - params = "l"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "L"; - dispatcher = "movewindow"; - params = "r"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "K"; - dispatcher = "movewindow"; - params = "u"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "J"; - dispatcher = "movewindow"; - params = "d"; - } + { + flags = []; + mods = ["SUPER"]; + key = "RETURN"; + dispatcher = "exec"; + params = "kitty"; + } - { - flags = ["e"]; - mods = ["SUPER"]; - key = "Left"; - dispatcher = "moveactive"; - params = "-50 0"; - } - { - flags = ["e"]; - mods = ["SUPER"]; - key = "Right"; - dispatcher = "moveactive"; - params = "50 0"; - } - { - flags = ["e"]; - mods = ["SUPER"]; - key = "Up"; - dispatcher = "moveactive"; - params = "0 -50"; - } - { - flags = ["e"]; - mods = ["SUPER"]; - key = "Down"; - dispatcher = "moveactive"; - params = "0 50"; - } + { + flags = []; + mods = ["SUPER"]; + key = "Q"; + dispatcher = "killactive"; + params = ""; + } - { - flags = ["e"]; - mods = ["SUPER" "SHIFT"]; - key = "Left"; - dispatcher = "resizeactive"; - params = "-50 0"; - } - { - flags = ["e"]; - mods = ["SUPER" "SHIFT"]; - key = "Right"; - dispatcher = "resizeactive"; - params = "50 0"; - } - { - flags = ["e"]; - mods = ["SUPER" "SHIFT"]; - key = "Up"; - dispatcher = "resizeactive"; - params = "0 -50"; - } - { - flags = ["e"]; - mods = ["SUPER" "SHIFT"]; - key = "Down"; - dispatcher = "resizeactive"; - params = "0 50"; - } + { + flags = []; + mods = []; + key = "F11"; + dispatcher = "fullscreen"; + params = ""; + } + { + flags = ["o"]; + mods = ["SUPER"]; + key = "L"; + dispatcher = "exec"; + params = "hyprlock"; + } + { + flags = ["e"]; + mods = ["SUPER"]; + key = "TAB"; + dispatcher = "changegroupactive"; + params = "f"; + } - { - flags = []; - mods = ["SUPER"]; - key = "grave"; - dispatcher = "togglespecialworkspace"; - params = ""; - } - { - flags = []; - mods = ["SUPER"]; - key = "1"; - dispatcher = "workspace"; - params = "1"; - } - { - flags = []; - mods = ["SUPER"]; - key = "2"; - dispatcher = "workspace"; - params = "2"; - } - { - flags = []; - mods = ["SUPER"]; - key = "3"; - dispatcher = "workspace"; - params = "3"; - } - { - flags = []; - mods = ["SUPER"]; - key = "4"; - dispatcher = "workspace"; - params = "4"; - } - { - flags = []; - mods = ["SUPER"]; - key = "5"; - dispatcher = "workspace"; - params = "5"; - } - { - flags = []; - mods = ["SUPER"]; - key = "6"; - dispatcher = "workspace"; - params = "6"; - } - { - flags = []; - mods = ["SUPER"]; - key = "7"; - dispatcher = "workspace"; - params = "7"; - } - { - flags = []; - mods = ["SUPER"]; - key = "8"; - dispatcher = "workspace"; - params = "8"; - } - { - flags = []; - mods = ["SUPER"]; - key = "9"; - dispatcher = "workspace"; - params = "9"; - } - { - flags = []; - mods = ["SUPER"]; - key = "0"; - dispatcher = "workspace"; - params = "10"; - } + { + flags = ["e"]; + mods = ["SUPER" "SHIFT"]; + key = "TAB"; + dispatcher = "changegroupactive"; + params = "b"; + } + { + flags = []; + mods = ["SUPER"]; + key = "F"; + dispatcher = "togglefloating"; + params = ""; + } + { + flags = []; + mods = ["SUPER"]; + key = "T"; + dispatcher = "togglegroup"; + params = ""; + } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "grave"; - dispatcher = "movetoworkspace"; - params = "special"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "1"; - dispatcher = "movetoworkspace"; - params = "1"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "2"; - dispatcher = "movetoworkspace"; - params = "2"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "3"; - dispatcher = "movetoworkspace"; - params = "3"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "4"; - dispatcher = "movetoworkspace"; - params = "4"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "5"; - dispatcher = "movetoworkspace"; - params = "5"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "6"; - dispatcher = "movetoworkspace"; - params = "6"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "7"; - dispatcher = "movetoworkspace"; - params = "7"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "8"; - dispatcher = "movetoworkspace"; - params = "8"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "9"; - dispatcher = "movetoworkspace"; - params = "9"; - } - { - flags = []; - mods = ["SUPER" "SHIFT"]; - key = "0"; - dispatcher = "movetoworkspace"; - params = "10"; - } + { + flags = []; + mods = ["SUPER"]; + key = "P"; + dispatcher = "pin"; + params = ""; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "S"; + dispatcher = "exec"; + params = "hyprshot -m region --clipboard-only"; + } - { - flags = ["e"]; - mods = ["SUPER" "CONTROL"]; - key = "Right"; - dispatcher = "workspace"; - params = "e+1"; - } - { - flags = ["e"]; - mods = ["SUPER" "CONTROL"]; - key = "Left"; - dispatcher = "workspace"; - params = "e-1"; - } + { + flags = []; + mods = ["SUPER"]; + key = "H"; + dispatcher = "movefocus"; + params = "l"; + } + { + flags = []; + mods = ["SUPER"]; + key = "L"; + dispatcher = "movefocus"; + params = "r"; + } + { + flags = []; + mods = ["SUPER"]; + key = "K"; + dispatcher = "movefocus"; + params = "u"; + } + { + flags = []; + mods = ["SUPER"]; + key = "J"; + dispatcher = "movefocus"; + params = "d"; + } - { - flags = ["m"]; - mods = ["SUPER"]; - key = "mouse:272"; - dispatcher = "movewindow"; - params = ""; - } - { - flags = ["m"]; - mods = ["SUPER" "SHIFT"]; - key = "mouse:272"; - dispatcher = "resizewindow"; - params = ""; - } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "H"; + dispatcher = "movewindow"; + params = "l"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "L"; + dispatcher = "movewindow"; + params = "r"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "K"; + dispatcher = "movewindow"; + params = "u"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "J"; + dispatcher = "movewindow"; + params = "d"; + } - { - flags = ["e" "l"]; - mods = []; - key = "XF86AudioRaiseVolume"; - dispatcher = "exec"; - params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 5%+"; - } - { - flags = ["e" "l"]; - mods = []; - key = "XF86AudioLowerVolume"; - dispatcher = "exec"; - params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 5%-"; - } - { - flags = ["e" "l"]; - mods = ["SHIFT"]; - key = "XF86AudioRaiseVolume"; - dispatcher = "exec"; - params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 1%+"; - } - { - flags = ["e" "l"]; - mods = ["SHIFT"]; - key = "XF86AudioLowerVolume"; - dispatcher = "exec"; - params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 1%-"; - } - { - flags = ["e" "l"]; - mods = []; - key = "XF86AudioMute"; - dispatcher = "exec"; - params = "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"; - } - { - flags = ["e" "l"]; - mods = []; - key = "XF86AudioMicMute"; - dispatcher = "exec"; - params = "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle"; - } - { - flags = ["e" "l"]; - mods = []; - key = "XF86MonBrightnessUp"; - dispatcher = "exec"; - params = "brightnessctl s 10%+"; - } - { - flags = ["e" "l"]; - mods = []; - key = "XF86MonBrightnessDown"; - dispatcher = "exec"; - params = "brightnessctl s 10%-"; - } - { - flags = ["l"]; - mods = []; - key = "XF86AudioNext"; - dispatcher = "exec"; - params = "playerctl next"; - } - { - flags = ["l"]; - mods = []; - key = "XF86AudioPause"; - dispatcher = "exec"; - params = "playerctl play-pause"; - } - { - flags = ["l"]; - mods = []; - key = "XF86AudioPlay"; - dispatcher = "exec"; - params = "playerctl play-pause"; - } - { - flags = ["l"]; - mods = []; - key = "XF86AudioPrev"; - dispatcher = "exec"; - params = "playerctl previous"; - } - ]; - }; + { + flags = ["e"]; + mods = ["SUPER"]; + key = "Left"; + dispatcher = "moveactive"; + params = "-50 0"; + } + { + flags = ["e"]; + mods = ["SUPER"]; + key = "Right"; + dispatcher = "moveactive"; + params = "50 0"; + } + { + flags = ["e"]; + mods = ["SUPER"]; + key = "Up"; + dispatcher = "moveactive"; + params = "0 -50"; + } + { + flags = ["e"]; + mods = ["SUPER"]; + key = "Down"; + dispatcher = "moveactive"; + params = "0 50"; + } + + { + flags = ["e"]; + mods = ["SUPER" "SHIFT"]; + key = "Left"; + dispatcher = "resizeactive"; + params = "-50 0"; + } + { + flags = ["e"]; + mods = ["SUPER" "SHIFT"]; + key = "Right"; + dispatcher = "resizeactive"; + params = "50 0"; + } + { + flags = ["e"]; + mods = ["SUPER" "SHIFT"]; + key = "Up"; + dispatcher = "resizeactive"; + params = "0 -50"; + } + { + flags = ["e"]; + mods = ["SUPER" "SHIFT"]; + key = "Down"; + dispatcher = "resizeactive"; + params = "0 50"; + } + + { + flags = []; + mods = ["SUPER"]; + key = "grave"; + dispatcher = "togglespecialworkspace"; + params = ""; + } + { + flags = []; + mods = ["SUPER"]; + key = "1"; + dispatcher = "workspace"; + params = "1"; + } + { + flags = []; + mods = ["SUPER"]; + key = "2"; + dispatcher = "workspace"; + params = "2"; + } + { + flags = []; + mods = ["SUPER"]; + key = "3"; + dispatcher = "workspace"; + params = "3"; + } + { + flags = []; + mods = ["SUPER"]; + key = "4"; + dispatcher = "workspace"; + params = "4"; + } + { + flags = []; + mods = ["SUPER"]; + key = "5"; + dispatcher = "workspace"; + params = "5"; + } + { + flags = []; + mods = ["SUPER"]; + key = "6"; + dispatcher = "workspace"; + params = "6"; + } + { + flags = []; + mods = ["SUPER"]; + key = "7"; + dispatcher = "workspace"; + params = "7"; + } + { + flags = []; + mods = ["SUPER"]; + key = "8"; + dispatcher = "workspace"; + params = "8"; + } + { + flags = []; + mods = ["SUPER"]; + key = "9"; + dispatcher = "workspace"; + params = "9"; + } + { + flags = []; + mods = ["SUPER"]; + key = "0"; + dispatcher = "workspace"; + params = "10"; + } + + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "grave"; + dispatcher = "movetoworkspace"; + params = "special"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "1"; + dispatcher = "movetoworkspace"; + params = "1"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "2"; + dispatcher = "movetoworkspace"; + params = "2"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "3"; + dispatcher = "movetoworkspace"; + params = "3"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "4"; + dispatcher = "movetoworkspace"; + params = "4"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "5"; + dispatcher = "movetoworkspace"; + params = "5"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "6"; + dispatcher = "movetoworkspace"; + params = "6"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "7"; + dispatcher = "movetoworkspace"; + params = "7"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "8"; + dispatcher = "movetoworkspace"; + params = "8"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "9"; + dispatcher = "movetoworkspace"; + params = "9"; + } + { + flags = []; + mods = ["SUPER" "SHIFT"]; + key = "0"; + dispatcher = "movetoworkspace"; + params = "10"; + } + + { + flags = ["e"]; + mods = ["SUPER" "CONTROL"]; + key = "Right"; + dispatcher = "workspace"; + params = "e+1"; + } + { + flags = ["e"]; + mods = ["SUPER" "CONTROL"]; + key = "Left"; + dispatcher = "workspace"; + params = "e-1"; + } + + { + flags = ["m"]; + mods = ["SUPER"]; + key = "mouse:272"; + dispatcher = "movewindow"; + params = ""; + } + { + flags = ["m"]; + mods = ["SUPER" "SHIFT"]; + key = "mouse:272"; + dispatcher = "resizewindow"; + params = ""; + } + + { + flags = ["e" "l"]; + mods = []; + key = "XF86AudioRaiseVolume"; + dispatcher = "exec"; + params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 5%+"; + } + { + flags = ["e" "l"]; + mods = []; + key = "XF86AudioLowerVolume"; + dispatcher = "exec"; + params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 5%-"; + } + { + flags = ["e" "l"]; + mods = ["SHIFT"]; + key = "XF86AudioRaiseVolume"; + dispatcher = "exec"; + params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 1%+"; + } + { + flags = ["e" "l"]; + mods = ["SHIFT"]; + key = "XF86AudioLowerVolume"; + dispatcher = "exec"; + params = "wpctl set-volume -l 1.0 @DEFAULT_AUDIO_SINK@ 1%-"; + } + { + flags = ["e" "l"]; + mods = []; + key = "XF86AudioMute"; + dispatcher = "exec"; + params = "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"; + } + { + flags = ["e" "l"]; + mods = []; + key = "XF86AudioMicMute"; + dispatcher = "exec"; + params = "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle"; + } + { + flags = ["e" "l"]; + mods = []; + key = "XF86MonBrightnessUp"; + dispatcher = "exec"; + params = "brightnessctl s 10%+"; + } + { + flags = ["e" "l"]; + mods = []; + key = "XF86MonBrightnessDown"; + dispatcher = "exec"; + params = "brightnessctl s 10%-"; + } + { + flags = ["l"]; + mods = []; + key = "XF86AudioNext"; + dispatcher = "exec"; + params = "playerctl next"; + } + { + flags = ["l"]; + mods = []; + key = "XF86AudioPause"; + dispatcher = "exec"; + params = "playerctl play-pause"; + } + { + flags = ["l"]; + mods = []; + key = "XF86AudioPlay"; + dispatcher = "exec"; + params = "playerctl play-pause"; + } + { + flags = ["l"]; + mods = []; + key = "XF86AudioPrev"; + dispatcher = "exec"; + params = "playerctl previous"; + } + ]; }; }; } diff --git a/modules/wm/hyprland/options.nix b/modules/wm/hyprland/options.nix index 0cc2b11..7ff1625 100644 --- a/modules/wm/hyprland/options.nix +++ b/modules/wm/hyprland/options.nix @@ -11,217 +11,30 @@ cfg = config.horseman.wm.hyprland; homeCfg = config.horseman; - - keybinding = types.submodule { - options = { - flags = mkOption { - type = types.listOf (types.enum ["l" "r" "c" "g" "o" "e" "m" "t" "i" "s" "d" "p"]); - }; - - mods = mkOption { - type = types.listOf types.str; - }; - - key = mkOption { - type = types.str; - }; - - dispatcher = mkOption { - type = types.str; - }; - - params = mkOption { - type = types.str; - }; - }; - }; - submapKeybinding = types.submodule { - options = { - flags = mkOption { - type = types.listOf (types.enum ["l" "r" "c" "g" "o" "e" "m" "t" "i" "s" "d" "p"]); - }; - - mods = mkOption { - type = types.listOf types.str; - }; - - key = mkOption { - type = types.str; - }; - }; - }; - vec2 = types.submodule { - options = { - x = mkOption {type = types.int;}; - y = mkOption {type = types.int;}; - }; - }; - fontWeight = types.enum ["thin" "ultralight" "light" "semilight" "book" "normal" "medium" "semibold" "bold" "ultrabold" "heavy" "ultraheavy"]; in { - options.horseman.wm.hyprland.config = { - execOnce = mkOption { - type = types.listOf types.str; - default = []; - }; - env = mkOption { - type = types.listOf types.str; - default = []; - }; - windowrules = mkOption { - type = types.listOf types.str; - default = []; - }; - workspaces = mkOption { - type = types.listOf types.str; - default = []; - }; - - animations = { - beziers = mkOption { - type = types.listOf (types.submodule { - options = { - name = mkOption {type = types.str;}; - startX = mkOption {type = types.number;}; - startY = mkOption {type = types.number;}; - endX = mkOption {type = types.number;}; - endY = mkOption {type = types.number;}; - }; - }); + options.horseman.wm.hyprland.config.waybar = { + layout = { + horizontal = { + left = mkOption {type = types.listOf types.str;}; + center = mkOption {type = types.listOf types.str;}; + right = mkOption {type = types.listOf types.str;}; }; - - animations = mkOption { - type = types.listOf (types.submodule { - options = { - name = mkOption {type = types.str;}; - on = mkOption {type = types.bool;}; - speed = mkOption { - type = types.number; - default = 0; - }; - curve = mkOption { - type = types.str; - default = ""; - }; - style = mkOption { - type = types.str; - default = ""; - }; - }; - }); + vertical = { + left = mkOption {type = types.listOf types.str;}; + center = mkOption {type = types.listOf types.str;}; + right = mkOption {type = types.listOf types.str;}; }; }; - - dwindle = { - pseudotile = mkOption {type = types.bool;}; - preserveSplit = mkOption {type = types.bool;}; - }; - - master = { - newStatus = mkOption {type = types.enum ["master" "slave" "inherit"];}; - }; - - monitors = { - defaultMonitor = mkOption {type = types.bool;}; - bindWorkspaces = mkOption { - type = types.enum ["no" "interlaced"]; - default = "no"; - }; - - displays = mkOption { - type = types.listOf (types.submodule { - options = { - output = mkOption {type = types.str;}; - resolution = mkOption { - type = types.str; - default = "highres"; - }; - refreshRate = mkOption { - type = types.str; - default = "highrr"; - }; - x = mkOption {type = types.int;}; - y = mkOption {type = types.int;}; - scale = mkOption { - type = types.number; - default = 1; - }; - transform = mkOption { - type = types.enum [0 1 2 3 4 5 6 7]; - default = 0; - }; - wallpaper = mkOption { - type = types.nullOr types.path; - default = null; - }; - bar = mkOption { - type = types.enum ["" "left" "right" "top" "bottom"]; - default = ""; - }; - }; - }); - }; - }; - - keybindings = { - binds = mkOption {type = types.listOf keybinding;}; - - submaps = mkOption { - type = types.listOf (types.submodule { - options = { - name = mkOption {type = types.str;}; - enterBind = mkOption {type = submapKeybinding;}; - exitBind = mkOption {type = submapKeybinding;}; - binds = mkOption {type = types.listOf keybinding;}; - }; - }); - }; - }; - - sleep = { - lockCommand = mkOption {type = types.str;}; - - listeners = mkOption { - type = types.listOf (types.submodule { - options = { - timeout = mkOption {type = types.ints.positive;}; - onTimeout = mkOption {type = types.str;}; - onResume = mkOption { - type = types.str; - default = ""; - }; - ignoreInhibit = mkOption { - type = types.bool; - default = false; - }; - }; - }); - }; - }; - - waybar = { - layout = { - horizontal = { - left = mkOption {type = types.listOf types.str;}; - center = mkOption {type = types.listOf types.str;}; - right = mkOption {type = types.listOf types.str;}; - }; - vertical = { - left = mkOption {type = types.listOf types.str;}; - center = mkOption {type = types.listOf types.str;}; - right = mkOption {type = types.listOf types.str;}; - }; - }; - formats = { - horizontal = mkOption { - type = types.attrs; - }; - vertical = mkOption { - type = types.attrs; - }; - }; - modules = mkOption { + formats = { + horizontal = mkOption { type = types.attrs; }; + vertical = mkOption { + type = types.attrs; + }; + }; + modules = mkOption { + type = types.attrs; }; }; @@ -229,12 +42,6 @@ in { horseman.dots = { fuzzel.enable = true; waybar.enable = true; - hypr = { - hyprland.enable = true; - hypridle.enable = true; - hyprpaper.enable = true; - hyprlock.enable = true; - }; }; home-manager.users.${homeCfg.username} = { @@ -248,7 +55,7 @@ in { if (disp.bar == location) then disp.output else null) - cfg.config.monitors.displays + config.nix-hyprland.monitors.displays ) ); in { From 6848a9d5e0e39797556abd458c692d0ddf0620e2 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 7 Jan 2026 16:58:48 +0100 Subject: [PATCH 11/16] idk changes --- flake.lock | 33 +++++++++++++++++--------------- flake.nix | 2 +- {overlays => lib}/catppuccin.nix | 0 {overlays => lib}/default.nix | 0 machines/artemis/modules.nix | 2 +- machines/terra/modules.nix | 4 ++-- modules/wm/hyprland/default.nix | 3 +++ 7 files changed, 25 insertions(+), 19 deletions(-) rename {overlays => lib}/catppuccin.nix (100%) rename {overlays => lib}/default.nix (100%) diff --git a/flake.lock b/flake.lock index 463d13b..c3ba809 100644 --- a/flake.lock +++ b/flake.lock @@ -73,11 +73,11 @@ ] }, "locked": { - "lastModified": 1766292113, - "narHash": "sha256-sWTtmkQujRpjWYCnZc8LWdDiCzrRlSBPrGovkZpLkBI=", + "lastModified": 1767780135, + "narHash": "sha256-5SbmsLMgxzPd9YMbFR4IHfOXv6bjWs+dfl6IbSq3r7s=", "owner": "nix-community", "repo": "home-manager", - "rev": "fdec8815a86db36f42fc9c8cb2931cd8485f5aed", + "rev": "c08430923ed417abc653884328a39e98496cfd0f", "type": "github" }, "original": { @@ -115,14 +115,17 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1767799636, - "narHash": "sha256-qBgbE4jC/VJaY86mNspzToyR08xacawAbMeZskejcJc=", - "path": "/home/horseman/Programming/nix-hyprland", - "type": "path" + "lastModified": 1767801421, + "narHash": "sha256-z6+cVdgkJSz+MLUOChLDUZsiBP/h6tuAZSjVG+66jpo=", + "owner": "KoenDR06", + "repo": "nix-hyprland", + "rev": "4efff468c6435080b0716fd289ab7c06c4bb215f", + "type": "github" }, "original": { - "path": "/home/horseman/Programming/nix-hyprland", - "type": "path" + "owner": "KoenDR06", + "repo": "nix-hyprland", + "type": "github" } }, "nixpkgs": { @@ -143,11 +146,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1766201043, - "narHash": "sha256-eplAP+rorKKd0gNjV3rA6+0WMzb1X1i16F5m5pASnjA=", + "lastModified": 1767634882, + "narHash": "sha256-2GffSfQxe3sedHzK+sTKlYo/NTIAGzbFCIsNMUPAAnk=", "owner": "nixos", "repo": "nixpkgs", - "rev": "b3aad468604d3e488d627c0b43984eb60e75e782", + "rev": "3c9db02515ef1d9b6b709fc60ba9a540957f661c", "type": "github" }, "original": { @@ -167,11 +170,11 @@ ] }, "locked": { - "lastModified": 1763909441, - "narHash": "sha256-56LwV51TX/FhgX+5LCG6akQ5KrOWuKgcJa+eUsRMxsc=", + "lastModified": 1767662275, + "narHash": "sha256-d5Q1GmQ+sW1Bt8cgDE0vOihzLaswsm8cSdg8124EqXE=", "owner": "pjones", "repo": "plasma-manager", - "rev": "b24ed4b272256dfc1cc2291f89a9821d5f9e14b4", + "rev": "51816be33a1ff0d4b22427de83222d5bfa96d30e", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 1972966..fac8c98 100644 --- a/flake.nix +++ b/flake.nix @@ -52,7 +52,7 @@ ]; forAllSystems = nixpkgs.lib.genAttrs systems; - lib = import ./overlays {inherit inputs;}; + lib = import ./lib {inherit inputs;}; in { formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra); diff --git a/overlays/catppuccin.nix b/lib/catppuccin.nix similarity index 100% rename from overlays/catppuccin.nix rename to lib/catppuccin.nix diff --git a/overlays/default.nix b/lib/default.nix similarity index 100% rename from overlays/default.nix rename to lib/default.nix diff --git a/machines/artemis/modules.nix b/machines/artemis/modules.nix index 5f94a9d..d1bad07 100644 --- a/machines/artemis/modules.nix +++ b/machines/artemis/modules.nix @@ -3,7 +3,7 @@ ../../modules ]; - nix-hyprland = { + config.nix-hyprland = { monitors = { bindWorkspaces = "interlaced"; displays = [ diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index fdce395..43c8e46 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -1,10 +1,9 @@ -{config, ...}: { +{...}: { imports = [ ../../modules ]; config.nix-hyprland = { - username = config.horseman.username; monitors = { displays = [ { @@ -19,6 +18,7 @@ y = 0; transform = 1; wallpaper = ../../misc/portrait.png; + bar = "top"; } ]; bindWorkspaces = "interlaced"; diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index 09962f5..59428ce 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -46,6 +46,9 @@ in { horseman.hardware.keyd.enable = true; nix-hyprland = { + enable = true; + username = config.horseman.username; + execOnce = [ "hypridle" "hyprpaper" From 74356e3041098f9a1cc21f9179040150289c9007 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 7 Jan 2026 17:02:03 +0100 Subject: [PATCH 12/16] update flake inputs --- flake.lock | 48 +++++++----------------------------------------- flake.nix | 2 ++ 2 files changed, 9 insertions(+), 41 deletions(-) diff --git a/flake.lock b/flake.lock index c3ba809..e679881 100644 --- a/flake.lock +++ b/flake.lock @@ -87,32 +87,14 @@ "type": "github" } }, - "home-manager_3": { - "inputs": { - "nixpkgs": [ - "nix-hyprland", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1767280655, - "narHash": "sha256-YmaYMduV5ko8zURUT1VLGDbVC1L/bxHS0NsiPoZ6bBM=", - "owner": "nix-community", - "repo": "home-manager", - "rev": "d49d2543f02dbd789ed032188c84570d929223cb", - "type": "github" - }, - "original": { - "owner": "nix-community", - "ref": "release-25.11", - "repo": "home-manager", - "type": "github" - } - }, "nix-hyprland": { "inputs": { - "home-manager": "home-manager_3", - "nixpkgs": "nixpkgs" + "home-manager": [ + "home-manager" + ], + "nixpkgs": [ + "nixpkgs" + ] }, "locked": { "lastModified": 1767801421, @@ -129,22 +111,6 @@ } }, "nixpkgs": { - "locked": { - "lastModified": 1767325753, - "narHash": "sha256-yA/CuWyqm+AQo2ivGy6PlYrjZBQm7jfbe461+4HF2fo=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "64049ca74d63e971b627b5f3178d95642e61cedd", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixos-25.11", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_2": { "locked": { "lastModified": 1767634882, "narHash": "sha256-2GffSfQxe3sedHzK+sTKlYo/NTIAGzbFCIsNMUPAAnk=", @@ -188,7 +154,7 @@ "agenix": "agenix", "home-manager": "home-manager_2", "nix-hyprland": "nix-hyprland", - "nixpkgs": "nixpkgs_2", + "nixpkgs": "nixpkgs", "plasma-manager": "plasma-manager" } }, diff --git a/flake.nix b/flake.nix index fac8c98..5bf8c32 100644 --- a/flake.nix +++ b/flake.nix @@ -22,6 +22,8 @@ nix-hyprland = { url = "github:KoenDR06/nix-hyprland"; + inputs.nixpkgs.follows = "nixpkgs"; + inputs.home-manager.follows = "home-manager"; }; }; From 4e7fcaf3a59938287c6a1184d8efc89d7a5f7b4d Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Fri, 16 Jan 2026 13:11:27 +0100 Subject: [PATCH 13/16] add firefox extensions in private mode --- modules/apps/visual/firefox.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/apps/visual/firefox.nix b/modules/apps/visual/firefox.nix index 1531e29..607ccf7 100644 --- a/modules/apps/visual/firefox.nix +++ b/modules/apps/visual/firefox.nix @@ -64,6 +64,7 @@ in { "uBlock0@raymondhill.net" = { install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi"; installation_mode = "force_installed"; + private_browsing = true; }; # Dark Reader "addon@darkreader.org" = { @@ -89,6 +90,7 @@ in { "idcac-pub@guus.ninja" = { install_url = "https://addons.mozilla.org/firefox/downloads/latest/istilldontcareaboutcookies/latest.xpi"; installation_mode = "force_installed"; + private_browsing = true; }; }; From c5c233509ca3c9c1bc199259155c80da3eb2b817 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 19 Jan 2026 17:22:12 +0100 Subject: [PATCH 14/16] Add power menu to hyprland --- misc/power-menu.sh | 12 ++++++++++++ modules/wm/hyprland/keybindings.nix | 11 +++++++++++ 2 files changed, 23 insertions(+) create mode 100755 misc/power-menu.sh diff --git a/misc/power-menu.sh b/misc/power-menu.sh new file mode 100755 index 0000000..34f2f6b --- /dev/null +++ b/misc/power-menu.sh @@ -0,0 +1,12 @@ +cmds=('shutdown now' 'reboot' 'hyprlock' 'hyprctl dispatch exit') + +count=${#cmds[@]} +default=15 + +lines=$((count > default ? default : count)) + +a=$(printf ' Shut down\n Reboot\n Lock\n Log out' | fuzzel --dmenu --index --lines $lines --placeholder "Power action: " -I) + +if [ -n "$a" ]; then + ${cmds[a]} +fi diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index fcef0a8..a91699c 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -1,6 +1,7 @@ { lib, config, + pkgs, ... }: let inherit (lib) mkIf; @@ -43,6 +44,16 @@ in { params = "pkill waybar || waybar"; } + { + flags = []; + mods = ["SUPER"]; + key = "P"; + dispatcher = "exec"; + params = let + a = pkgs.writeShellScriptBin "power-menu" (builtins.readFile ../../../misc/power-menu.sh); + in "pkill fuzzel || ${a}/bin/power-menu"; + } + { flags = []; mods = ["SUPER"]; From 284da9f58a42c606d87e99b38fb4a94697d5dc0e Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 19 Jan 2026 19:04:05 +0100 Subject: [PATCH 15/16] sound menu --- dots/.config/fuzzel/fuzzel.ini.nix | 9 ++++----- dots/.config/waybar/style.css.nix | 7 +++---- dots/.config/wofi/style.css.nix | 11 +++++------ machines/artemis/modules.nix | 5 ++++- machines/terra/modules.nix | 5 ++++- misc/power-menu.sh | 2 +- misc/sound-menu.sh | 14 ++++++++++++++ modules/catppuccin/default.nix | 2 +- modules/wm/hyprland/default.nix | 5 ++--- modules/wm/hyprland/keybindings.nix | 10 ++++++++++ 10 files changed, 48 insertions(+), 22 deletions(-) create mode 100755 misc/sound-menu.sh diff --git a/dots/.config/fuzzel/fuzzel.ini.nix b/dots/.config/fuzzel/fuzzel.ini.nix index b45a3c0..e5b6efb 100644 --- a/dots/.config/fuzzel/fuzzel.ini.nix +++ b/dots/.config/fuzzel/fuzzel.ini.nix @@ -7,7 +7,6 @@ cfg = config.horseman.dots.fuzzel; username = config.horseman.username; colors = config.horseman.catppuccin.colors; - accent = config.horseman.catppuccin.accent; in { options = { horseman.dots.fuzzel = { @@ -20,15 +19,15 @@ in { [colors] background=${catppuccin.toHexNoHash colors.base}dd text=${catppuccin.toHexNoHash colors.text}ff - prompt=${catppuccin.toHexNoHash colors.subtext1}ff + prompt=${catppuccin.toHexNoHash colors.accent}ff placeholder=${catppuccin.toHexNoHash colors.overlay1}ff input=${catppuccin.toHexNoHash colors.text}ff - match=${catppuccin.toHexNoHash colors.${accent}}ff + match=${catppuccin.toHexNoHash colors.accent}ff selection=${catppuccin.toHexNoHash colors.surface2}ff selection-text=${catppuccin.toHexNoHash colors.text}ff - selection-match=${catppuccin.toHexNoHash colors.${accent}}ff + selection-match=${catppuccin.toHexNoHash colors.accent}ff counter=${catppuccin.toHexNoHash colors.overlay1}ff - border=${catppuccin.toHexNoHash colors.${accent}}ff + border=${catppuccin.toHexNoHash colors.accent}ff [main] font=CaskaydiaCoveNerdFont:weight=semilight diff --git a/dots/.config/waybar/style.css.nix b/dots/.config/waybar/style.css.nix index c2c7d82..ccf18e8 100644 --- a/dots/.config/waybar/style.css.nix +++ b/dots/.config/waybar/style.css.nix @@ -7,7 +7,6 @@ cfg = config.horseman.dots.waybar; username = config.horseman.username; colors = config.horseman.catppuccin.colors; - accent = config.horseman.catppuccin.accent; in { options = { horseman.dots.waybar = { @@ -26,7 +25,7 @@ in { } .modules-left, .modules-center, .modules-right { - border: 2px solid ${catppuccin.toHex colors.${accent}}; + border: 2px solid ${catppuccin.toHex colors.accent}; border-radius: 10px; margin: 5px; background: ${catppuccin.toHex colors.base}; @@ -40,7 +39,7 @@ in { color: ${catppuccin.toHex colors.red}; } #power * { - color: ${catppuccin.toHex colors.${accent}}; + color: ${catppuccin.toHex colors.accent}; transition: 0.2s color ease; font-size: 26px; } @@ -62,7 +61,7 @@ in { } #workspaces > * { - color: ${catppuccin.toHex colors.${accent}}; + color: ${catppuccin.toHex colors.accent}; } diff --git a/dots/.config/wofi/style.css.nix b/dots/.config/wofi/style.css.nix index f010423..3457fd5 100644 --- a/dots/.config/wofi/style.css.nix +++ b/dots/.config/wofi/style.css.nix @@ -7,7 +7,6 @@ cfg = config.horseman.dots.wofi; username = config.horseman.username; colors = config.horseman.catppuccin.colors; - accent = config.horseman.catppuccin.accent; in { options = { horseman.dots.wofi = { @@ -26,7 +25,7 @@ in { window { margin: 0px; padding: 10px; - border: 3px solid ${catppuccin.toHex colors.${accent}}; + border: 3px solid ${catppuccin.toHex colors.accent}; border-radius: 10px; background-color: ${catppuccin.toRGBA colors.base 0.99}; /* animation: slideIn 0.5s ease-in-out both; */ @@ -83,7 +82,7 @@ in { #input { margin: 5px 20px; padding: 10px; - border: 2px solid ${catppuccin.toHex colors.${accent}}; + border: 2px solid ${catppuccin.toHex colors.accent}; border-radius: 10px; color: ${catppuccin.toHex colors.text}; background-color: ${catppuccin.toHex colors.base}; @@ -113,7 +112,7 @@ in { #entry arrow { border: none; - color: ${catppuccin.toHex colors.${accent}}; + color: ${catppuccin.toHex colors.accent}; } /* Selected Entry */ @@ -123,7 +122,7 @@ in { } #entry:selected { - border: 1px solid ${catppuccin.toHex colors.${accent}}; + border: 1px solid ${catppuccin.toHex colors.accent}; border-radius: 10px; } @@ -132,7 +131,7 @@ in { } #entry:drop(active) { - background-color: ${catppuccin.toHex colors.${accent}}!important; + background-color: ${catppuccin.toHex colors.accent}!important; } ''; }; diff --git a/machines/artemis/modules.nix b/machines/artemis/modules.nix index d1bad07..e4c0f29 100644 --- a/machines/artemis/modules.nix +++ b/machines/artemis/modules.nix @@ -21,7 +21,10 @@ config.horseman = { dots.kitty.fontSize = 13; - catppuccin.flavor = "mocha"; + catppuccin = { + flavor = "mocha"; + accent = "blue"; + }; users.default.enable = true; diff --git a/machines/terra/modules.nix b/machines/terra/modules.nix index 43c8e46..6601368 100644 --- a/machines/terra/modules.nix +++ b/machines/terra/modules.nix @@ -26,7 +26,10 @@ }; config.horseman = { - catppuccin.flavor = "mocha"; + catppuccin = { + flavor = "mocha"; + accent = "blue"; + }; users.default.enable = true; diff --git a/misc/power-menu.sh b/misc/power-menu.sh index 34f2f6b..3a8be49 100755 --- a/misc/power-menu.sh +++ b/misc/power-menu.sh @@ -5,7 +5,7 @@ default=15 lines=$((count > default ? default : count)) -a=$(printf ' Shut down\n Reboot\n Lock\n Log out' | fuzzel --dmenu --index --lines $lines --placeholder "Power action: " -I) +a=$(printf ' Shut down\n Reboot\n Lock\n Log out' | fuzzel --cache /dev/null --dmenu --index --lines $lines --placeholder "Power action: " -I) if [ -n "$a" ]; then ${cmds[a]} diff --git a/misc/sound-menu.sh b/misc/sound-menu.sh new file mode 100755 index 0000000..1676471 --- /dev/null +++ b/misc/sound-menu.sh @@ -0,0 +1,14 @@ +mapfile -t ids < <(wpctl status | sed -n '/Audio/,/Video/p' | sed -n '/├─ Sinks:/,/├─ Sources:/p' | tail -n +2 | head -n -2 | sed -r 's/^........//' | sed -r 's/\. .*//') + +mapfile -t sinks < <(wpctl status | sed -n '/Audio/,/Video/p' | sed -n '/├─ Sinks:/,/├─ Sources:/p' | tail -n +2 | head -n -2 | sed -r 's/^........//' | sed -r 's/[0-9]+\. //') + +count=${#ids[@]} +default=15 + +lines=$((count > default ? default : count)) + +a=$(printf '%s\n' "${sinks[@]}" | fuzzel --cache /dev/null --dmenu --index --lines $lines --placeholder "Switch audio source: " -I) + +if [ -n "$a" ]; then + wpctl set-default ${ids[a]} +fi diff --git a/modules/catppuccin/default.nix b/modules/catppuccin/default.nix index e6adb02..4e5af6c 100644 --- a/modules/catppuccin/default.nix +++ b/modules/catppuccin/default.nix @@ -597,5 +597,5 @@ in { }; }; - config.horseman.catppuccin.colors = lib.mkDefault flavors.${cfg.flavor}; + config.horseman.catppuccin.colors = lib.mkDefault (flavors.${cfg.flavor} // {accent = cfg.flavor.${cfg.accent};}); } diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index 59428ce..908eb2b 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -8,7 +8,6 @@ cfg = config.horseman.wm.hyprland; colors = config.horseman.catppuccin.colors; - accent = config.horseman.catppuccin.accent; in { imports = [ ./options.nix @@ -90,8 +89,8 @@ in { resizeOnBorder = true; allowTearing = false; - col.activeBorder = catppuccin.toRGB colors.${accent}; - col.inactiveBorder = catppuccin.toRGBA colors.${accent} 0.25; + col.activeBorder = catppuccin.toRGB colors.accent; + col.inactiveBorder = catppuccin.toRGBA colors.accent 0.25; layout = "dwindle"; }; diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index a91699c..0c2ec5c 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -54,6 +54,16 @@ in { in "pkill fuzzel || ${a}/bin/power-menu"; } + { + flags = []; + mods = ["SUPER"]; + key = "S"; + dispatcher = "exec"; + params = let + a = pkgs.writeShellScriptBin "sound-menu" (builtins.readFile ../../../misc/sound-menu.sh); + in "pkill fuzzel || ${a}/bin/sound-menu"; + } + { flags = []; mods = ["SUPER"]; From c40729a68fb7559dd91e11b27ab26b61aeaf59a4 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Mon, 19 Jan 2026 22:11:28 +0100 Subject: [PATCH 16/16] remove comment --- lib/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/default.nix b/lib/default.nix index 17e93fa..14223ae 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -1,4 +1,3 @@ -# {inputs, ...}: import ./catppuccin.nix {inherit inputs;} {inputs, ...}: inputs.nixpkgs.lib.extend ( final: prev: {