3
0
Fork 0
forked from mirrors/nixpkgs

treewide: treewide: use lib.optionalAttrs instead of 'then {}'

add missing parentheses.
This commit is contained in:
Pol Dellaiera 2023-06-13 23:06:37 +02:00
parent 8fcb368580
commit ae35046326
No known key found for this signature in database
GPG key ID: D476DFE9C67467CA

View file

@ -4,7 +4,7 @@ let
skipBuildPhase = x: {
overrides = y: ((x.overrides y) // { buildPhase = "true"; });
};
multiOverride = l: x: pkgs.lib.optionalAttrs (l != []) ((builtins.head l) x) // (multiOverride (builtins.tail l) x);
multiOverride = l: x: pkgs.lib.optionalAttrs (l != []) (((builtins.head l) x) // (multiOverride (builtins.tail l) x));
lispName = (clwrapper.lisp.pname or (builtins.parseDrvName clwrapper.lisp.name).name);
ifLispIn = l: f: if (pkgs.lib.elem lispName l) then f else (x: {});
ifLispNotIn = l: f: if ! (pkgs.lib.elem lispName l) then f else (x: {});