Skip to content

Commit

Permalink
allow nullable packages
Browse files Browse the repository at this point in the history
this makes it possible to express that a package may be needed for
an application to be useful but is not available yet.
  • Loading branch information
fricklerhandwerk committed Nov 26, 2024
1 parent e577386 commit 75ccbdf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion projects/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
(lib.attrsets)
concatMapAttrs
mapAttrs
filterAttrs
;

baseDirectory = ./.;
Expand Down Expand Up @@ -54,7 +55,7 @@
# - `null` means "expected but missing"
# - not set means "not applicable"
project: {
packages = empty-if-null (project.packages or {});
packages = empty-if-null (filterAttrs (name: value: value != null) (project.packages or {}));
nixos.modules = empty-if-null (project.nixos.modules or {});
nixos.examples = empty-if-null (project.nixos.examples or {});
nixos.tests =
Expand Down

0 comments on commit 75ccbdf

Please sign in to comment.