diff options
| -rw-r--r-- | flake.lock | 48 | ||||
| -rw-r--r-- | share/cfg/wpaperd.nix | 3 | ||||
| -rw-r--r-- | share/hm-modules/default.nix | 1 | ||||
| -rw-r--r-- | share/hm-modules/wpaperd.nix | 77 |
4 files changed, 24 insertions, 105 deletions
@@ -27,11 +27,11 @@ ] }, "locked": { - "lastModified": 1739841949, - "narHash": "sha256-lSOXdgW/1zi/SSu7xp71v+55D5Egz8ACv0STkj7fhbs=", + "lastModified": 1740485968, + "narHash": "sha256-WK+PZHbfDjLyveXAxpnrfagiFgZWaTJglewBWniTn2Y=", "owner": "nix-community", "repo": "disko", - "rev": "15dbf8cebd8e2655a883b74547108e089f051bf0", + "rev": "19c1140419c4f1cdf88ad4c1cfb6605597628940", "type": "github" }, "original": { @@ -48,11 +48,11 @@ "nixpkgs-stable": "nixpkgs-stable" }, "locked": { - "lastModified": 1740215630, - "narHash": "sha256-4refjC2/FOnNe99qL63mwloVlXtQ73oos/jqjap2ZFo=", + "lastModified": 1740734258, + "narHash": "sha256-sHUy8ZjsPybSOvl8j4ifwTOFLYu8rKa9wLCxTyzuDB0=", "owner": "nix-community", "repo": "emacs-overlay", - "rev": "10d666ad8ae003661063ac31ec97bf8412365e00", + "rev": "502293ae094f7ecd604500ffb19ad35bd429311b", "type": "github" }, "original": { @@ -203,11 +203,11 @@ ] }, "locked": { - "lastModified": 1740208222, - "narHash": "sha256-FqgPcK5BK+Mc4cGBCGz555UsVd/TQK9FvmuamBWu+ZY=", + "lastModified": 1740699498, + "narHash": "sha256-r9hkKzX99CGiP1ZqH0e+SWKK4CMsRNRLyotuwrUjhTI=", "owner": "nix-community", "repo": "home-manager", - "rev": "f4a07823a298deff0efb0db30f9318511de7c232", + "rev": "b71edac7a3167026aabea82a54d08b1794088c21", "type": "github" }, "original": { @@ -269,11 +269,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1739866667, - "narHash": "sha256-EO1ygNKZlsAC9avfcwHkKGMsmipUk1Uc0TbrEZpkn64=", + "lastModified": 1740560979, + "narHash": "sha256-Vr3Qi346M+8CjedtbyUevIGDZW8LcA1fTG0ugPY/Hic=", "owner": "nixos", "repo": "nixpkgs", - "rev": "73cf49b8ad837ade2de76f87eb53fc85ed5d4680", + "rev": "5135c59491985879812717f4c9fea69604e7f26f", "type": "github" }, "original": { @@ -329,11 +329,11 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1739923778, - "narHash": "sha256-BqUY8tz0AQ4to2Z4+uaKczh81zsGZSYxjgvtw+fvIfM=", + "lastModified": 1740603184, + "narHash": "sha256-t+VaahjQAWyA+Ctn2idyo1yxRIYpaDxMgHkgCNiMJa4=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "36864ed72f234b9540da4cf7a0c49e351d30d3f1", + "rev": "f44bd8ca21e026135061a0a57dcf3d0775b67a49", "type": "github" }, "original": { @@ -361,11 +361,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1739866667, - "narHash": "sha256-EO1ygNKZlsAC9avfcwHkKGMsmipUk1Uc0TbrEZpkn64=", + "lastModified": 1740560979, + "narHash": "sha256-Vr3Qi346M+8CjedtbyUevIGDZW8LcA1fTG0ugPY/Hic=", "owner": "nixos", "repo": "nixpkgs", - "rev": "73cf49b8ad837ade2de76f87eb53fc85ed5d4680", + "rev": "5135c59491985879812717f4c9fea69604e7f26f", "type": "github" }, "original": { @@ -452,11 +452,11 @@ "treefmt-nix": "treefmt-nix" }, "locked": { - "lastModified": 1740219286, - "narHash": "sha256-IvYKRrx24/yDQvQk/1pJhm2ngxjSTBqi2g5Ly8pgkxA=", + "lastModified": 1740741040, + "narHash": "sha256-Soa/CeI8F4jGKEWqCJ2Y9UMxKWndJrwZAPkVE6K1x1A=", "owner": "nix-community", "repo": "nur", - "rev": "6cec53b34684074b57e92c4a017160a8ae7b7b37", + "rev": "e264ef93dafdd178520977cd1b45bb320d102e99", "type": "github" }, "original": { @@ -513,11 +513,11 @@ ] }, "locked": { - "lastModified": 1740191166, - "narHash": "sha256-WqRxO1Afx8jPYG4CKwkvDFWFvDLCwCd4mxb97hFGYPg=", + "lastModified": 1740709839, + "narHash": "sha256-4dF++MXIXna/AwlZWDKr7bgUmY4xoEwvkF1GewjNrt0=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "74a3fb71b0cc67376ab9e7c31abcd68c813fc226", + "rev": "b4270835bf43c6f80285adac6f66a26d83f0f277", "type": "github" }, "original": { diff --git a/share/cfg/wpaperd.nix b/share/cfg/wpaperd.nix index 3760caf..aeb5638 100644 --- a/share/cfg/wpaperd.nix +++ b/share/cfg/wpaperd.nix @@ -1,6 +1,3 @@ -# IMPORTANT: this is the config for a custom module that's located at -# /share/hm-modules/wpaperd.nix. In order to use this config you have to also -# import that module. { config, ... }: let wallpapers-dir = "${config.xdg.userDirs.pictures}/Wallpapers"; diff --git a/share/hm-modules/default.nix b/share/hm-modules/default.nix index c4ddc87..cc04898 100644 --- a/share/hm-modules/default.nix +++ b/share/hm-modules/default.nix @@ -2,6 +2,5 @@ { imports = [ ./hyprdesktop.nix - ./wpaperd.nix ]; } diff --git a/share/hm-modules/wpaperd.nix b/share/hm-modules/wpaperd.nix deleted file mode 100644 index 82aacb5..0000000 --- a/share/hm-modules/wpaperd.nix +++ /dev/null @@ -1,77 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: -with lib; -let - cfg = config.services.wpaperd; - tomlFormat = pkgs.formats.toml { }; -in -{ - options.services.wpaperd = { - enable = mkEnableOption "enable wpaperd"; - - package = mkOption { - default = pkgs.wpaperd; - defaultText = literalExpression "pkgs.wpaperd"; - type = types.package; - example = literalExpression "pkgs.wpaperd"; - description = "The package to use for the wpaperd binary."; - }; - - settings = mkOption { - type = tomlFormat.type; - description = '' - Configuration for wpaperd. Options are specified on: - https://github.com/danyspin97/wpaperd#wallpaper-configuration - ''; - example = literalExpression '' - { - default = { - path = "/home/myusername/Pictures/Wallpapers/"; - duration = "10m" - sorting = "random"; - }; - } - ''; - }; - - systemdTarget = mkOption { - type = types.str; - default = "hyprland-session.target"; - description = '' - Systemd target to bind to. - Note: if you're using home-manager to configure hyprland, you want to - have `wayland.windowManager.hyprland.systemdIntegration` enabled. - ''; - }; - }; - - config = mkIf cfg.enable { - assertions = [ (hm.assertions.assertPlatform "services.wpaperd" pkgs platforms.linux) ]; - - home.packages = [ cfg.package ]; - - xdg.configFile = { - "wpaperd/wallpaper.toml" = mkIf (cfg.settings != { }) { - source = tomlFormat.generate "wpaperd-config" cfg.settings; - }; - }; - - systemd.user.services.wpaperd = { - Unit = { - Description = "Wallpaper daemon for Wayland"; - BindsTo = [ cfg.systemdTarget ]; - }; - - Service = { - Type = "simple"; - ExecStart = "${cfg.package}/bin/wpaperd"; - }; - - Install.WantedBy = [ cfg.systemdTarget ]; - }; - }; -} |
