diff options
author | Gaetan Lepage <gaetan@glepage.com> | 2023-01-15 16:57:13 +0100 |
---|---|---|
committer | Gaetan Lepage <gaetan@glepage.com> | 2023-01-15 16:57:13 +0100 |
commit | d599e734e5de8f2cfbd143a218c50b48b3db40c4 (patch) | |
tree | ef038ae3b328f85466bbc83a33bdac5cc8a4564f | |
parent | 162545d3fdf3c7c02ca8eb0d8dc3d6aec7cae2ea (diff) | |
download | nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.tar nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.tar.gz nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.tar.bz2 nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.tar.lz nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.tar.xz nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.tar.zst nixpkgs-d599e734e5de8f2cfbd143a218c50b48b3db40c4.zip |
autorandr: 1.12.1 -> 1.13, nixos/services/autorandr: add ignoreLeadOption
-rw-r--r-- | nixos/modules/services/misc/autorandr.nix | 14 | ||||
-rw-r--r-- | pkgs/tools/misc/autorandr/default.nix | 4 |
2 files changed, 15 insertions, 3 deletions
diff --git a/nixos/modules/services/misc/autorandr.nix b/nixos/modules/services/misc/autorandr.nix index 072064143db..aa96acb6130 100644 --- a/nixos/modules/services/misc/autorandr.nix +++ b/nixos/modules/services/misc/autorandr.nix @@ -254,6 +254,12 @@ in { ''; }; + ignoreLid = mkOption { + default = false; + type = types.bool; + description = lib.mdDoc "Treat outputs as connected even if their lids are closed"; + }; + hooks = mkOption { type = hooksModule; description = lib.mdDoc "Global hook scripts"; @@ -340,7 +346,13 @@ in { startLimitIntervalSec = 5; startLimitBurst = 1; serviceConfig = { - ExecStart = "${pkgs.autorandr}/bin/autorandr --batch --change --default ${cfg.defaultTarget}"; + ExecStart = '' + ${pkgs.autorandr}/bin/autorandr \ + --batch \ + --change \ + --default ${cfg.defaultTarget} \ + ${optionalString cfg.ignoreLid "--ignore-lid"} + ''; Type = "oneshot"; RemainAfterExit = false; KillMode = "process"; diff --git a/pkgs/tools/misc/autorandr/default.nix b/pkgs/tools/misc/autorandr/default.nix index eb1ce13f310..1f22401a419 100644 --- a/pkgs/tools/misc/autorandr/default.nix +++ b/pkgs/tools/misc/autorandr/default.nix @@ -8,7 +8,7 @@ python3.pkgs.buildPythonApplication rec { pname = "autorandr"; - version = "1.12.1"; + version = "1.13"; format = "other"; nativeBuildInputs = [ installShellFiles ]; @@ -59,7 +59,7 @@ python3.pkgs.buildPythonApplication rec { owner = "phillipberndt"; repo = "autorandr"; rev = version; - sha256 = "sha256-7SNnbgV6PeseBD6wdilEIOfOL2KVDpnlkSn9SBgRhhM="; + sha256 = "sha256-pTWwDKBCZV3wkX/VHuWrwMFgUAMDvik11y+ysKiN3HU="; }; meta = with lib; { |