From 8c17b9cea1381f1e65c083ec95978ee771fcbca1 Mon Sep 17 00:00:00 2001 From: xenia Date: Mon, 16 Sep 2024 14:23:32 +0200 Subject: [PATCH] Update tiny-dfr to 0.3.1 --- flake.nix | 2 +- nixos/tiny-dfr.nix | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/flake.nix b/flake.nix index aef1444c..5ebed9d5 100644 --- a/flake.nix +++ b/flake.nix @@ -211,7 +211,7 @@ ref = "main"; rev = "012d29d4b4d7148414bb649c39805479c7a4327b"; }; - tiny-dfr = import ./nixos/tiny-dfr.nix { inherit pkgs; }; + tiny-dfr = import ./nixos/tiny-dfr.nix { pkgs = pkgs-unstable; }; in nixpkgs.lib.nixosSystem { inherit system; diff --git a/nixos/tiny-dfr.nix b/nixos/tiny-dfr.nix index ee1fe92f..3f124cd6 100644 --- a/nixos/tiny-dfr.nix +++ b/nixos/tiny-dfr.nix @@ -1,13 +1,16 @@ { pkgs, tiny-dfr ? pkgs.tiny-dfr -}: { +}: + assert tiny-dfr.version == "0.3.1"; +{ services.udev.packages = [ tiny-dfr ]; systemd.services.tiny-dfr = { enable = true; - description = "tinydfr"; - after = ["systemd-user-sessions.service" "getty@tty1.service" "plymouth-quit.service" "systemd-logind.service"]; + description = "tiny-dfr"; + after = ["systemd-user-sessions.service" "getty@tty1.service" "plymouth-quit.service" "systemd-logind.service" "dev-tiny_dfr_display.device" "dev-tiny_dfr_backlight.device" "dev-tiny_dfr_display_backlight.device"]; wantedBy = ["multi-user.target"]; + bindsTo = ["dev-tiny_dfr_display.device" "dev-tiny_dfr_backlight.device" "dev-tiny_dfr_display_backlight.device"]; startLimitIntervalSec = 30; startLimitBurst = 2; serviceConfig = {