Closed noverby closed 8 months ago
Hmm, I'm not sure how this would generalize.
Right now we have, in order that is checked for:
nix/packages.nix
returns the value to set packages
to. This is pretty clear what the user intended.nix/packages/default.nix
returns the value to set packages
to. With Nix it would be expected that default.nix
should set what the folder evaluates to, and allows user to keep full control but put all files in a packages
folder.nix/packages/
without a default.nix
grabs all the nix files in the directory and sets packages
to an attrset with names from file names mapping to importing that file. This makes sense since with nix/packages/a.nix
and nix/packages/b.nix
, the user wants to set packages.a
and packages.b
.Not sure what nix/packages/pkg-group/pkg1.nix
would be. I would assume it would set packages.pkg-group.pkg1
though that is not valid since packages.x86_64-linux.pkg-group.pkg1
is not valid. Only attribute, as far as I know, that allows arbitrary structure is legacyPackages
.
It seems autoloading is only supporting one directory level for autoloading.
So this works:
But not this: