From d914e05efcfbfc6209fed9b8f14be4a197d000f7 Mon Sep 17 00:00:00 2001 From: martyTF Date: Tue, 23 Dec 2025 07:34:39 +0100 Subject: [PATCH] trying hyprland plugins but no worky :sadge: --- flake.lock | 555 +++++++++++++++++++++++++++++++++-- flake.nix | 6 + modules/desktop/hyprland.nix | 37 ++- 3 files changed, 577 insertions(+), 21 deletions(-) diff --git a/flake.lock b/flake.lock index 193b23f..da442d0 100644 --- a/flake.lock +++ b/flake.lock @@ -1,5 +1,38 @@ { "nodes": { + "aquamarine": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1765900596, + "narHash": "sha256-+hn8v9jkkLP9m+o0Nm5SiEq10W0iWDSotH2XfjU45fA=", + "owner": "hyprwm", + "repo": "aquamarine", + "rev": "d83c97f8f5c0aae553c1489c7d9eff3eadcadace", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "aquamarine", + "type": "github" + } + }, "elephant": { "inputs": { "nixpkgs": "nixpkgs", @@ -36,6 +69,22 @@ } }, "flake-compat_2": { + "flake": false, + "locked": { + "lastModified": 1761588595, + "narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_3": { "flake": false, "locked": { "lastModified": 1747046372, @@ -69,6 +118,28 @@ "type": "github" } }, + "gitignore": { + "inputs": { + "nixpkgs": [ + "hyprland", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1709087332, + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -76,11 +147,11 @@ ] }, "locked": { - "lastModified": 1766282146, - "narHash": "sha256-0V/nKU93KdYGi+5LB/MVo355obBJw/2z9b2xS3bPJxY=", + "lastModified": 1766387499, + "narHash": "sha256-AjK3/UKDzeXFeYNLVBaJ3+HLE9he1g5UrlNd4/BM3eA=", "owner": "nix-community", "repo": "home-manager", - "rev": "61fcc9de76b88e55578eb5d79fc80f2b236df707", + "rev": "527ad07e6625302b648ed3b28c34b62a79bd103e", "type": "github" }, "original": { @@ -89,11 +160,360 @@ "type": "github" } }, + "hyprcursor": { + "inputs": { + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1753964049, + "narHash": "sha256-lIqabfBY7z/OANxHoPeIrDJrFyYy9jAM4GQLzZ2feCM=", + "owner": "hyprwm", + "repo": "hyprcursor", + "rev": "44e91d467bdad8dcf8bbd2ac7cf49972540980a5", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprcursor", + "type": "github" + } + }, + "hyprgraphics": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1763733840, + "narHash": "sha256-JnET78yl5RvpGuDQy3rCycOCkiKoLr5DN1fPhRNNMco=", + "owner": "hyprwm", + "repo": "hyprgraphics", + "rev": "8f1bec691b2d198c60cccabca7a94add2df4ed1a", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprgraphics", + "type": "github" + } + }, + "hyprland": { + "inputs": { + "aquamarine": "aquamarine", + "hyprcursor": "hyprcursor", + "hyprgraphics": "hyprgraphics", + "hyprland-guiutils": "hyprland-guiutils", + "hyprland-protocols": "hyprland-protocols", + "hyprlang": "hyprlang", + "hyprutils": "hyprutils", + "hyprwayland-scanner": "hyprwayland-scanner", + "hyprwire": "hyprwire", + "nixpkgs": "nixpkgs_2", + "pre-commit-hooks": "pre-commit-hooks", + "systems": "systems_2", + "xdph": "xdph" + }, + "locked": { + "lastModified": 1766422408, + "narHash": "sha256-eWwTRcHCo2E1RwUKn4NcBrI9P8OCSEwBRhCp8/MJrbI=", + "owner": "hyprwm", + "repo": "Hyprland", + "rev": "abffe75088e2d776e14e5dbd726a835fa157df9a", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "Hyprland", + "type": "github" + } + }, + "hyprland-guiutils": { + "inputs": { + "aquamarine": [ + "hyprland", + "aquamarine" + ], + "hyprgraphics": [ + "hyprland", + "hyprgraphics" + ], + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "hyprtoolkit": "hyprtoolkit", + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1765643131, + "narHash": "sha256-CCGohW5EBIRy4B7vTyBMqPgsNcaNenVad/wszfddET0=", + "owner": "hyprwm", + "repo": "hyprland-guiutils", + "rev": "e50ae912813bdfa8372d62daf454f48d6df02297", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-guiutils", + "type": "github" + } + }, + "hyprland-plugins": { + "inputs": { + "hyprland": [ + "hyprland" + ], + "nixpkgs": [ + "hyprland-plugins", + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland-plugins", + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1766258034, + "narHash": "sha256-0EoL8X+sYexDBusF9XyY2WoGKRqnARA+vfh/3uAi/j0=", + "owner": "hyprwm", + "repo": "hyprland-plugins", + "rev": "3e29d68d5a830c542643a52d4be726661eaa85e7", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-plugins", + "type": "github" + } + }, + "hyprland-protocols": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1765214753, + "narHash": "sha256-P9zdGXOzToJJgu5sVjv7oeOGPIIwrd9hAUAP3PsmBBs=", + "owner": "hyprwm", + "repo": "hyprland-protocols", + "rev": "3f3860b869014c00e8b9e0528c7b4ddc335c21ab", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-protocols", + "type": "github" + } + }, + "hyprlang": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1764612430, + "narHash": "sha256-54ltTSbI6W+qYGMchAgCR6QnC1kOdKXN6X6pJhOWxFg=", + "owner": "hyprwm", + "repo": "hyprlang", + "rev": "0d00dc118981531aa731150b6ea551ef037acddd", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprlang", + "type": "github" + } + }, + "hyprtoolkit": { + "inputs": { + "aquamarine": [ + "hyprland", + "hyprland-guiutils", + "aquamarine" + ], + "hyprgraphics": [ + "hyprland", + "hyprland-guiutils", + "hyprgraphics" + ], + "hyprlang": [ + "hyprland", + "hyprland-guiutils", + "hyprlang" + ], + "hyprutils": [ + "hyprland", + "hyprland-guiutils", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprland-guiutils", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "hyprland-guiutils", + "nixpkgs" + ], + "systems": [ + "hyprland", + "hyprland-guiutils", + "systems" + ] + }, + "locked": { + "lastModified": 1764592794, + "narHash": "sha256-7CcO+wbTJ1L1NBQHierHzheQGPWwkIQug/w+fhTAVuU=", + "owner": "hyprwm", + "repo": "hyprtoolkit", + "rev": "5cfe0743f0e608e1462972303778d8a0859ee63e", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprtoolkit", + "type": "github" + } + }, + "hyprutils": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1766160771, + "narHash": "sha256-roINUGikWRqqgKrD4iotKbGj3ZKJl3hjMz5l/SyKrHw=", + "owner": "hyprwm", + "repo": "hyprutils", + "rev": "5ac060bfcf2f12b3a6381156ebbc13826a05b09f", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprutils", + "type": "github" + } + }, + "hyprwayland-scanner": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1763640274, + "narHash": "sha256-Uan1Nl9i4TF/kyFoHnTq1bd/rsWh4GAK/9/jDqLbY5A=", + "owner": "hyprwm", + "repo": "hyprwayland-scanner", + "rev": "f6cf414ca0e16a4d30198fd670ec86df3c89f671", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprwayland-scanner", + "type": "github" + } + }, + "hyprwire": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1766253200, + "narHash": "sha256-26qPwrd3od+xoYVywSB7hC2cz9ivN46VPLlrsXyGxvE=", + "owner": "hyprwm", + "repo": "hyprwire", + "rev": "1079777525b30a947c8d657fac158e00ae85de9d", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprwire", + "type": "github" + } + }, "nixos-cli": { "inputs": { - "flake-compat": "flake-compat", + "flake-compat": "flake-compat_2", "flake-parts": "flake-parts", - "nixpkgs": "nixpkgs_2", + "nixpkgs": "nixpkgs_3", "optnix": "optnix" }, "locked": { @@ -142,6 +562,22 @@ } }, "nixpkgs_2": { + "locked": { + "lastModified": 1766070988, + "narHash": "sha256-G/WVghka6c4bAzMhTwT2vjLccg/awmHkdKSd2JrycLc=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "c6245e83d836d0433170a16eb185cefe0572f8b8", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_3": { "locked": { "lastModified": 1764527385, "narHash": "sha256-nA5ywiGKl76atrbdZ5Aucd8SjF/v8ew9b9QsC+MKL14=", @@ -157,7 +593,7 @@ "type": "github" } }, - "nixpkgs_3": { + "nixpkgs_4": { "locked": { "lastModified": 1759070547, "narHash": "sha256-JVZl8NaVRYb0+381nl7LvPE+A774/dRpif01FKLrYFQ=", @@ -173,13 +609,13 @@ "type": "github" } }, - "nixpkgs_4": { + "nixpkgs_5": { "locked": { - "lastModified": 1766070988, - "narHash": "sha256-G/WVghka6c4bAzMhTwT2vjLccg/awmHkdKSd2JrycLc=", + "lastModified": 1766309749, + "narHash": "sha256-3xY8CZ4rSnQ0NqGhMKAy5vgC+2IVK0NoVEzDoOh4DA4=", "owner": "nixos", "repo": "nixpkgs", - "rev": "c6245e83d836d0433170a16eb185cefe0572f8b8", + "rev": "a6531044f6d0bef691ea18d4d4ce44d0daa6e816", "type": "github" }, "original": { @@ -189,7 +625,7 @@ "type": "github" } }, - "nixpkgs_5": { + "nixpkgs_6": { "locked": { "lastModified": 1757068644, "narHash": "sha256-NOrUtIhTkIIumj1E/Rsv1J37Yi3xGStISEo8tZm3KW4=", @@ -207,8 +643,8 @@ }, "optnix": { "inputs": { - "flake-compat": "flake-compat_2", - "nixpkgs": "nixpkgs_3" + "flake-compat": "flake-compat_3", + "nixpkgs": "nixpkgs_4" }, "locked": { "lastModified": 1765418479, @@ -224,12 +660,37 @@ "type": "github" } }, + "pre-commit-hooks": { + "inputs": { + "flake-compat": "flake-compat", + "gitignore": "gitignore", + "nixpkgs": [ + "hyprland", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1765911976, + "narHash": "sha256-t3T/xm8zstHRLx+pIHxVpQTiySbKqcQbK+r+01XVKc0=", + "owner": "cachix", + "repo": "git-hooks.nix", + "rev": "b68b780b69702a090c8bb1b973bab13756cc7a27", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "git-hooks.nix", + "type": "github" + } + }, "root": { "inputs": { "elephant": "elephant", "home-manager": "home-manager", + "hyprland": "hyprland", + "hyprland-plugins": "hyprland-plugins", "nixos-cli": "nixos-cli", - "nixpkgs": "nixpkgs_4", + "nixpkgs": "nixpkgs_5", "walker": "walker", "zen-browser": "zen-browser" } @@ -264,13 +725,28 @@ "type": "github" } }, + "systems_3": { + "locked": { + "lastModified": 1689347949, + "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", + "owner": "nix-systems", + "repo": "default-linux", + "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default-linux", + "type": "github" + } + }, "walker": { "inputs": { "elephant": [ "elephant" ], - "nixpkgs": "nixpkgs_5", - "systems": "systems_2" + "nixpkgs": "nixpkgs_6", + "systems": "systems_3" }, "locked": { "lastModified": 1766324177, @@ -286,6 +762,47 @@ "type": "github" } }, + "xdph": { + "inputs": { + "hyprland-protocols": [ + "hyprland", + "hyprland-protocols" + ], + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1761431178, + "narHash": "sha256-xzjC1CV3+wpUQKNF+GnadnkeGUCJX+vgaWIZsnz9tzI=", + "owner": "hyprwm", + "repo": "xdg-desktop-portal-hyprland", + "rev": "4b8801228ff958d028f588f0c2b911dbf32297f9", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "xdg-desktop-portal-hyprland", + "type": "github" + } + }, "zen-browser": { "inputs": { "nixpkgs": [ @@ -293,11 +810,11 @@ ] }, "locked": { - "lastModified": 1765772419, - "narHash": "sha256-1mQ1K4fqebT54nz13rcRNjd6a+IbNLwLvYyR62EcyE8=", + "lastModified": 1766377218, + "narHash": "sha256-y3g3OqPB0tmRjbHJNnJKivSQRtAJR+/9S1xbxBWEatg=", "owner": "youwen5", "repo": "zen-browser-flake", - "rev": "227e836e43fe7985b4c4f8b0076446a6d66f3343", + "rev": "2f61341b32dd69c07e147188e67e09ba2bb99c33", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 8bd53f0..e401aaf 100644 --- a/flake.nix +++ b/flake.nix @@ -17,6 +17,12 @@ url = "github:youwen5/zen-browser-flake"; inputs.nixpkgs.follows = "nixpkgs"; }; + hyprland.url = "github:hyprwm/Hyprland"; + + hyprland-plugins = { + url = "github:hyprwm/hyprland-plugins"; + inputs.hyprland.follows = "hyprland"; + }; }; outputs = diff --git a/modules/desktop/hyprland.nix b/modules/desktop/hyprland.nix index 5532232..21571d6 100644 --- a/modules/desktop/hyprland.nix +++ b/modules/desktop/hyprland.nix @@ -2,6 +2,7 @@ config, lib, pkgs, + inputs, ... }: @@ -46,8 +47,12 @@ config = lib.mkIf config.desktop.hyprland.enable { xdg.portal = { enable = true; - configPackages = [ pkgs.xdg-desktop-portal-hyprland ]; - extraPortals = [ pkgs.xdg-desktop-portal-hyprland ]; + configPackages = [ + inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland + ]; + extraPortals = [ + inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland + ]; }; programs = { hyprlock = { @@ -56,10 +61,16 @@ }; wayland.windowManager.hyprland = { enable = true; + xwayland.enable = true; + systemd.enable = true; + package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; + portalPackage = + inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; settings = { monitor = config.desktop.hyprland.monitors; workspace = config.desktop.hyprland.workspaces.workspaces; exec-once = [ + "hyprctl plugin load " (lib.mkIf (config.desktop.walker.enable) "elephant") (lib.mkIf (config.desktop.waybar.enable) "waybar") (lib.mkIf (config.desktop.wallpaper.enable) "waypaper --restore --random") @@ -97,11 +108,13 @@ "$mod, K, exec, playerctl play-pause" "$mod, L, exec, playerctl, next" "$mod, G, togglefloating," + # "$mod, H, hyprexpo:expo, toggle" "$mod, F1, exec, hyprlock" "$shiftmod, E, exec, codium" "$controlmod, up, exec, light -A 10" "$controlmod, down, exec, light -U 10" "$controlmod, Q, exec, hyprctl kill" + ] ++ (builtins.concatLists ( builtins.genList ( @@ -152,7 +165,27 @@ color = "rgba(1a1a1aee)"; }; }; + plugin = { + hyprexpo = { + columns = 3; + gap_size = 20; + bg_col = "rgb(e1e1e2)"; + workspace_method = "first 1"; + enable_gesture = true; + gesture_distance = 300; + gesture_positive = true; + gesture_negative = true; + }; + hyprtrails = { + color = "rgba(1a1a1aee)"; + }; + }; }; + plugins = [ + inputs.hyprland-plugins.packages.${pkgs.stdenv.hostPlatform.system}.hyprtrails + inputs.hyprland-plugins.packages.${pkgs.stdenv.hostPlatform.system}.hyprexpo + + ]; }; home.sessionVariables.NIXOS_OZONE_WL = "1"; };