summary refs log tree commit diff
path: root/nixos/modules/services/misc/cgminer.nix
diff options
context:
space:
mode:
authorFelix Buehler <account@buehler.rocks>2023-06-24 20:19:19 +0200
committerFelix Buehler <account@buehler.rocks>2023-06-24 20:19:19 +0200
commitf3719756b550113c1acbbab00c89a56fb77256f2 (patch)
treea94f6678f9b1b25c6773bdd7a35422aabc816032 /nixos/modules/services/misc/cgminer.nix
parente9e3f2e7362aba3ef709173d1777f0b893fc0ebf (diff)
downloadnixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.tar
nixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.tar.gz
nixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.tar.bz2
nixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.tar.lz
nixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.tar.xz
nixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.tar.zst
nixpkgs-f3719756b550113c1acbbab00c89a56fb77256f2.zip
treewide: use optionalString instead of 'then ""'
Diffstat (limited to 'nixos/modules/services/misc/cgminer.nix')
-rw-r--r--nixos/modules/services/misc/cgminer.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/services/misc/cgminer.nix b/nixos/modules/services/misc/cgminer.nix
index fced106cb32..81eb42cbc5d 100644
--- a/nixos/modules/services/misc/cgminer.nix
+++ b/nixos/modules/services/misc/cgminer.nix
@@ -11,7 +11,7 @@ let
     mapAttrsToList (n: v: ''"${n}": "${(concatStringsSep "," (map convType v))}"'')
       (foldAttrs (n: a: [n] ++ a) [] cfg.hardware);
   mergedConfig = with builtins;
-    mapAttrsToList (n: v: ''"${n}":  ${if isBool v then "" else ''"''}${convType v}${if isBool v then "" else ''"''}'')
+    mapAttrsToList (n: v: ''"${n}":  ${if isBool v then (convType v) else ''"${convType v}"''}'')
       cfg.config;
 
   cgminerConfig = pkgs.writeText "cgminer.conf" ''