1
1
forked from extern/flakelight
Commit Graph

10 Commits

Author SHA1 Message Date
Archit Gupta
4e9f53ff4e Enable all options to be auto-loaded from nixDir
This removes the manual configuration of which options are auto-loaded.
Now all options are eligible except for "nixDir" and "_module" as those
would cause inf recursions.

Additionally, instead of setting name aliases in the nixDir module, a
config option is added, enabling other modules to extend the aliases
lists.
2024-01-15 00:07:59 -08:00
Archit Gupta
589ee5ba7a Make direct and auto-loaded configuration consistent
Many attributes can take moduleArgs when auto-loaded in order to
facilitate access to them from other files. Those same attributes could
not take moduleArgs when included directly, which was inconsistent.

With this change, all attributes that could take moduleArgs when
auto-loaded can now always do so. Auto-loading no longer needs special
cases.
2024-01-14 19:35:54 -08:00
Archit Gupta
f2c32f5a42 Add optCallWith type for optional calling
optFunctionTo results in a function which needs to be called when using
the option value. This is needed when the argument is not known when
building types (such as with pkgs). When the args are known (for
example, moduleArgs), this leads to more complex code than just calling
the function and resulting in the target type. optCallWith does the
latter.
2024-01-14 19:22:46 -08:00
Archit Gupta
5215a657bf Apply misc code cleanup 2024-01-14 12:59:39 -08:00
Archit Gupta
cc2f42fbdf Enable simpler config of nixos/home configurations
Instead of having to call the configuration generation functions, the
params can just be set, and the functions will be called automatically
with additional useful settings automatically set.
2024-01-14 02:19:34 -08:00
Archit Gupta
0760edb005 Refactor autoloadArgs to moduleArgs
The set of args passed to modules is useful for more than just
autoloading. This renames it appropriately and makes it available
through pkgs arguments as well.
2024-01-11 17:35:01 -08:00
Archit Gupta
395ac91da0 Minor refactor in (nixos|home)Configurations 2023-12-05 00:12:04 -08:00
Archit Gupta
6d00e0f544 Allow functions for NixOS or home-manager configurations
This allows a configuration to be set as a function that will be passed
autoloadArgs. This is useful when each configuration is in its own file
when autoloading.
2023-10-23 20:25:38 -07:00
Archit Gupta
b8d9538c58 Rename project from flakelite to flakelight 2023-08-26 22:48:57 -07:00
Archit Gupta
f6c4424f6e Reimplement framework using the module system 2023-08-26 22:39:28 -07:00