Merge pull request #309455 from c-leri/nixos/fix/thermald-adaptative

nixos/thermald: improve doc and code about configFile and adaptive

authored by Lin Jian and committed by GitHub 805191d9 b0ac16cd

+8 -3
+8 -3
nixos/modules/services/hardware/thermald.nix
··· 28 configFile = mkOption { 29 type = types.nullOr types.path; 30 default = null; 31 - description = "the thermald manual configuration file."; 32 }; 33 34 package = mkPackageOption pkgs "thermald" { }; ··· 49 --no-daemon \ 50 ${optionalString cfg.debug "--loglevel=debug"} \ 51 ${optionalString cfg.ignoreCpuidCheck "--ignore-cpuid-check"} \ 52 - ${optionalString (cfg.configFile != null) "--config-file ${cfg.configFile}"} \ 53 - ${optionalString (cfg.configFile == null) "--adaptive"} \ 54 --dbus-enable 55 ''; 56 };
··· 28 configFile = mkOption { 29 type = types.nullOr types.path; 30 default = null; 31 + description = '' 32 + The thermald manual configuration file. 33 + 34 + Leave unspecified to run with the `--adaptive` flag instead which will have thermald use your computer's DPTF adaptive tables. 35 + 36 + See `man thermald` for more information. 37 + ''; 38 }; 39 40 package = mkPackageOption pkgs "thermald" { }; ··· 55 --no-daemon \ 56 ${optionalString cfg.debug "--loglevel=debug"} \ 57 ${optionalString cfg.ignoreCpuidCheck "--ignore-cpuid-check"} \ 58 + ${if cfg.configFile != null then "--config-file ${cfg.configFile}" else "--adaptive"} \ 59 --dbus-enable 60 ''; 61 };