| Commit message (Collapse) | Author | Age |
|\
| |
| | |
lib/tests/modules: Test that _module.args works when a default argume…
|
| | |
|
|\ \
| | |
| | | |
lib/modules: handle typeless options in mergeModules
|
| | |
| | |
| | |
| | |
| | |
| | | |
mkOption does not require a `type` argument and does not set the
resulting attribute if it is not given. Consequently, we need to be
prepared to merge options that have no type information.
|
|\ \ \
| | | |
| | | | |
`lib.lists.{findFirstIndex,commonPrefix}`: init
|
| | | | |
|
| | |/
| |/|
| | |
| | | |
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
|
|\ \ \
| | | |
| | | | |
Create a Readme in `lib`
|
| | | | |
|
| |/ /
|/| |
| | |
| | | |
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
|
| | | |
|
|\ \ \
| | | |
| | | | |
lib.platforms.mips{,64}-embedded: init
|
| | |/
| |/| |
|
|/ /
| |
| |
| |
| |
| | |
Having the current bash hash present in the nixpkgs tree makes Nix
detect bash as a runtime dependency of nixpkgs, which in turns messes up
`fetchFromGitHub` due to https://github.com/NixOS/nix/issues/6660
|
| |
| |
| |
| |
| | |
Now that the lib is tested with Nix 2.3, this isn't needed any more and
causes warnings.
|
| |
| |
| |
| |
| | |
Add missing test cases. I think the .links case should be rejected
even though it's technically a path in the store.
|
|\ \
| | |
| | |
| | |
| | | |
hercules-ci/nixos-nixpkgs-dont-check-when-_module.args.pkgs-is-set
`nixos/nixpkgs`: Don't check when `_module.args.pkgs` is set
|
| | |
| | |
| | |
| | |
| | |
| | | |
This will let us make assertions involving _module.args.pkgs, which
is not an option but a value attribute, and therefore doesn't have
its own highestPrio to inspect. The new function gives us that info.
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
toLosslessStringMaybe is not used by anything other than lib/tests,
so it can be private to that file.
I don't think this function was terribly well thought-through. If
people start using it, we will become permanently dependent on the
ability to test platforms for equality. It also makes the
elaboration process more fragile, because it encourages code outside
of nixpkgs to become sensitive to the minute details of how
elaboration happens.
|
| | |
|
| |
| |
| |
| | |
Co-authored-by: Artturi <Artturin@artturin.com>
|
| | |
|
|\ \
| |/
|/| |
`lib.findFirst`: Add tests and make lazier
|
| |
| |
| |
| | |
There's no need to evaluate list elements after a matching element
|
| | |
|
|\ \
| | |
| | | |
Init `nixVersions.minimum` and fix `lib` tests for all Nix versions
|
| | |
| | |
| | |
| | |
| | | |
The previous commits ensure that the tests also succeed with those
versions
|
| | | |
|
| | | |
|
| |/ |
|
|/
|
|
|
|
| |
We already have examples for these, but since we didn't actually
recognise the doubles, it wasn't possible to build any packages for
them without setting allowUnsupportedSystem.
|
|\
| |
| | |
Improvements to pathType, pathIsDirectory and pathIsRegularFile
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously it would fail with
error: attribute 'nonexistent' missing
at nixpkgs/lib/filesystem.nix:29:10:
28| if dirOf path == path then "directory"
29| else (readDir (dirOf path)).${baseNameOf path};
| ^
30|
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously this function couldn't handle / being passed, it would throw
an error:
error: attribute '' missing
at nixpkgs/lib/filesystem.nix:24:20:
23| */
24| pathType = path: (readDir (dirOf path)).${baseNameOf path};
| ^
25|
Consequently this also fixes the
lib.filesystem.{pathIsDirectory,pathIsRegularFile} functions.
|
| |
| |
| |
| | |
Co-Authored-By: Robert Hensing <robert@roberthensing.nl>
|
| | |
|
| |
| |
| |
| | |
This simplifies the documentation. `configuration` is implied by `_type`.
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| | |
This is to avoid stealing keys from submodules. `class` might be
common enough that reinterpreting existing `class` attributes in
configurations as a declaration leads to fairly widespread problems.
|
| | |
|
| |
| |
| |
| |
| |
| | |
This is appears to be a fairly common mistake for beginners who want
to build larger things from the system configurations, such as NixOps
networks, etc. Further explanation seems appropriate.
|
| | |
|
| |
| |
| |
| |
| | |
This improves the error message when an incompatible module is
imported.
|
| |
| |
| |
| |
| | |
I had some trouble understanding this. Let's try to keep new tests
a bit more stateless and explicit.
|
|\ \
| | |
| | | |
lib.toPlist: Add support for path values
|
| | | |
|
| |/ |
|