summaryrefslogtreecommitdiff
path: root/home-manager/compositor/hyprland.nix
diff options
context:
space:
mode:
Diffstat (limited to 'home-manager/compositor/hyprland.nix')
-rw-r--r--home-manager/compositor/hyprland.nix108
1 files changed, 108 insertions, 0 deletions
diff --git a/home-manager/compositor/hyprland.nix b/home-manager/compositor/hyprland.nix
new file mode 100644
index 0000000..55133a4
--- /dev/null
+++ b/home-manager/compositor/hyprland.nix
@@ -0,0 +1,108 @@
+{ pkgs, ... }:
+{
+ wayland.windowManager.hyprland.enable = true;
+ wayland.windowManager.hyprland.systemd.enable = true;
+ wayland.windowManager.hyprland.settings = {
+ "$terminal" = "alacritty";
+ "$mod" = "SUPER";
+
+ exec-once = [
+ "waybar"
+ ];
+
+ general = {
+ "border_size" = 2;
+ "col.active_border" = "rgba(33ccffee) rgba(00ff99ee) 45deg";
+ "col.inactive_border" = "rgba(595959aa)";
+ };
+
+ monitor = [
+ "Unknown-1, disable"
+ ",preferred,auto,auto"
+ ];
+
+ animations = {
+ bezier = [
+ "easeOutQuint,0.23,1,0.32,1"
+ "easeInOutCubic,0.65,0.05,0.36,1"
+ "linear,0,0,1,1"
+ "almostLinear,0.5,0.5,0.75,1.0"
+ "quick,0.15,0,0.1,1"
+ ];
+ animation = [
+ "global, 1, 10, default"
+ "border, 1, 5.39, easeOutQuint"
+ "windows, 1, 4.79, easeOutQuint"
+ "windowsIn, 1, 4.1, easeOutQuint, popin 87%"
+ "windowsOut, 1, 1.49, linear, popin 87%"
+ "fadeIn, 1, 1.73, almostLinear"
+ "fadeOut, 1, 1.46, almostLinear"
+ "fade, 1, 3.03, quick"
+ "layers, 1, 3.81, easeOutQuint"
+ "layersIn, 1, 4, easeOutQuint, fade"
+ "layersOut, 1, 1.5, linear, fade"
+ "fadeLayersIn, 1, 1.79, almostLinear"
+ "fadeLayersOut, 1, 1.39, almostLinear"
+ "workspaces, 1, 1.94, almostLinear, fade"
+ ];
+ };
+
+ decoration = {
+ "rounding" = 5;
+ "inactive_opacity" = 0.8;
+ };
+
+ bind =
+ [
+ "$mod, D, exec, ${pkgs.rofi-wayland-unwrapped}/bin/rofi -show drun"
+ "$mod SHIFT, D, exec, ${pkgs.rofi-rbw}/bin/rofi-rbw"
+ "$mod, F, fullscreen, 1"
+ "$mod, Return, exec, alacritty"
+ "$mod SHIFT, Q, killactive"
+ "$mod, h, movefocus, l"
+ "$mod, j, movefocus, d"
+ "$mod, k, movefocus, u"
+ "$mod, l, movefocus, r"
+ "$mod SHIFT, h, swapwindow, l"
+ "$mod SHIFT, j, swapwindow, d"
+ "$mod SHIFT, k, swapwindow, u"
+ "$mod SHIFT, l, swapwindow, r"
+ ]
+ ++ (
+ builtins.concatLists (builtins.genList (i:
+ let ws = i + 1;
+ in [
+ "$mod, code:1${toString i}, workspace, ${toString ws}"
+ "$mod SHIFT, code:1${toString i}, movetoworkspace, ${toString ws}"
+ ]
+ )
+ 9)
+ );
+ };
+
+ programs.waybar.settings = {
+ mainBar = {
+ layer = "top";
+ position = "bottom";
+ output = [
+ "HDMI-A-1"
+ ];
+ modules-left = [
+ "hyprland/workspaces"
+ ];
+ modules-right = [
+ "clock"
+ ];
+
+ "hyprland/workspaces" = {
+ all-outputs = true;
+ format-icons = {
+ active = "";
+ default = "";
+ };
+ format = "{id} {icon}";
+ window-rewrite-default = "*";
+ };
+ };
+ };
+}