Skip to content

Commit 12f8b90

Browse files
committed
refactor: reuse nixgl.auto when nVidia is forced
Instead of duplicating its definition, because that leaves the possibility for bugs when these duplicates aren't in sync.
1 parent 378c68e commit 12f8b90

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

nixGL.nix

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -249,10 +249,5 @@ let
249249
nixGLCommon nixGLIntel;
250250
} // autoNvidia;
251251
};
252-
in top // (if nvidiaVersion != null then
253-
top.nvidiaPackages {
254-
version = nvidiaVersion;
255-
sha256 = nvidiaHash;
256-
}
257-
else
258-
{ })
252+
in top // lib.optionalAttrs (nvidiaVersion != null)
253+
(builtins.removeAttrs top.auto [ "nixGLDefault" ])

0 commit comments

Comments
 (0)