establish flakeArg construct & add docu

main
Felix Stupp 2 months ago
parent c27e5818c0
commit 91c72a02db
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -42,8 +42,17 @@
{ self, ... }@inputs:
let
inherit (self) outputs;
# every flake "submodule" gets this passed:
flakeArg = {
inherit self inputs outputs;
# Usage in submodule:
# { ... }@flakeArg: { }
# add "..." this so new ones can easily be added
inherit
# flake refs
self # reflection
inputs # evaluated inputs
outputs # evaluated outputs
;
};
# constants
system = "x86_64-linux";

@ -1,3 +1,5 @@
# nix configs & modules
This directory contains all nix-related (esp. NixOS) files.
Normally, I would have placed these directories on the same level as flake.nix, but:
@ -7,3 +9,8 @@ Normally, I would have placed these directories on the same level as flake.nix,
(i.e. also including systems without NixOS)
it also contains files for different systems.
These should be separated from nix files, in general.
## flakeArg
Every flake "submodule" gets passed a `flakeArg` parameter to access the flakes inputs & outputs and other goodies. This is documented in ../flake.nix.

Loading…
Cancel
Save