diff options
| author | tv <tv@krebsco.de> | 2026-11-13 20:34:59 +0000 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-11-13 22:01:29 +0100 |
| commit | 7768c71fd8083ea21572de2859fed39c17524baf (patch) | |
| tree | 1bccd536bef6adaa844c73478e8fc11900b0a85e /pkgs/populate/docs | |
| parent | 53eb98c0b2f808ca456717111facf21ca4a50015 (diff) | |
populate: check the settings of sources in the spec
The program checks that each source's settings are those
lib/types/populate.nix defines for its type, with values of the kinds
it defines, for specs from elsewhere than default.nix: a misspelt
setting fails, as design.md promises, instead of being ignored, and so
does a setting the program would treat as its default because of its
kind. This subsumes the check of absolute paths.
ln gets a symlink source's target after --, so it can't be taken for an
option either.
Diffstat (limited to 'pkgs/populate/docs')
| -rw-r--r-- | pkgs/populate/docs/design.md | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pkgs/populate/docs/design.md b/pkgs/populate/docs/design.md index 89bf581..6ad5eea 100644 --- a/pkgs/populate/docs/design.md +++ b/pkgs/populate/docs/design.md @@ -99,6 +99,10 @@ The program checks the spec as `checks.nix` does, with the same messages: neither `..` nor control characters. - Inputs get drawn from sources that exist, not from the source itself, and not in circles. +- The settings of a source are those `lib/types/populate.nix` defines for + its type, of the kinds it defines, e.g. absolute paths for the paths of + `file`, `pass`, and `pipe` sources. `checks.nix` doesn't repeat this, + since `evalSource` checks the types. Checks that depend on whether the target is local come on top, e.g. refusing to copy flakes to remote targets using sudo. `checks.nix` does |
