diff options
author | Robert Hensing <roberth@users.noreply.github.com> | 2022-09-28 10:27:45 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-28 10:27:45 +0100 |
commit | 7f0d934f9aa50d69336aec32fc90dada6d2d4459 (patch) | |
tree | 136f2150fdf25d2769d2bb50ea5a80891bd224d5 /lib/modules.nix | |
parent | 46e8398474ac3b1b7bb198bf9097fc213bbf59b1 (diff) | |
parent | 3ce4179374352b1407b1800cb97c1e08a07db4ca (diff) | |
download | nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.tar nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.tar.gz nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.tar.bz2 nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.tar.lz nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.tar.xz nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.tar.zst nixpkgs-7f0d934f9aa50d69336aec32fc90dada6d2d4459.zip |
Merge pull request #191540 from hercules-ci/nixosTest-modular
nixosTest: make modular
Diffstat (limited to 'lib/modules.nix')
-rw-r--r-- | lib/modules.nix | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/modules.nix b/lib/modules.nix index b6751d17f8f..46e22088a20 100644 --- a/lib/modules.nix +++ b/lib/modules.nix @@ -440,13 +440,14 @@ rec { config = addFreeformType (addMeta (m.config or {})); } else + # shorthand syntax lib.throwIfNot (isAttrs m) "module ${file} (${key}) does not look like a module." { _file = toString m._file or file; key = toString m.key or key; disabledModules = m.disabledModules or []; imports = m.require or [] ++ m.imports or []; options = {}; - config = addFreeformType (addMeta (removeAttrs m ["_file" "key" "disabledModules" "require" "imports" "freeformType"])); + config = addFreeformType (removeAttrs m ["_file" "key" "disabledModules" "require" "imports" "freeformType"]); }; applyModuleArgsIfFunction = key: f: args@{ config, options, lib, ... }: if isFunction f then |