about summary refs log tree commit diff
path: root/lib
Commit message (Collapse)AuthorAge
...
| * | | | | | | | | | Make behavior of `encodeGNUCommandLine` customizableGabriel Gonzalez2019-12-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... based on feedback from @edolstra
| * | | | | | | | | | Rename `renderOptions` to `encodeGNUCommandLine`Gabriel Gonzalez2019-12-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... as suggested by @edolstra
| * | | | | | | | | | Add `pkgs.lib.renderOptions`Gabriel Gonzalez2019-12-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds a new utility to intelligently convert Nix records to command line options to reduce boilerplate for simple use cases and to also reduce the likelihood of malformed command lines
* | | | | | | | | | | Merge pull request #77575 from worldofpeace/home-manager-warnings-dropworldofpeace2020-01-13
|\ \ \ \ \ \ \ \ \ \ \ | |_|_|_|_|_|_|_|_|/ / |/| | | | | | | | | | lib/types: dont warn loaOf for home-manager namespace
| * | | | | | | | | | lib/types: dont warn loaOf for home-manager namespaceworldofpeace2020-01-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This option namespace is not a part of NixOS so we shouldn't provide this warning for it.
* | | | | | | | | | | Merge pull request #77473 from mayflower/worktreesLinus Heckemann2020-01-13
|\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / |/| | | | | | | | | | lib.commitIdFromGitRepo: support git-worktree
| * | | | | | | | | | lib.commitIdFromGitRepo: support git-worktreeelseym2020-01-10
| | |_|_|_|_|_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lib.commitIdFromGitRepo now resolves the refs from the parent repository in case the supplied path is a file containing the path to said repository. this adds support for git-worktree and things alike. see gitrepository-layout(5). this also: - adds a new boolean function lib.pathIsRegularFile to check whether a path is a regular file - patches lib.revisionWithDefault and the revision and versionSuffix attributes in config.system.nixos in order to support git-worktrees
* | | | | | | | | | Merge pull request #77501 from jtojnar/more-loaof-fxesJan Tojnar2020-01-12
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | tree-wide: fix more warning related to loaOf deprecation
| * | | | | | | | | | lib/types: improve loaOf message even moreJan Tojnar2020-01-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now we suggest correct names for all options in Nixpkgs and also home-manager at the time of writing.
| * | | | | | | | | | lib/types: only show ... in loaOf warning when necessaryJan Tojnar2020-01-11
| | | | | | | | | | |
| * | | | | | | | | | lib/types: improve loaOf warningJan Tojnar2020-01-11
| |/ / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Not all modules use name attribute as the name of the submodule, for example, environment.etc uses target. We will need to maintain a list of exceptions.
* | | | | | | | | | Merge pull request #76861 from Infinisil/paths-as-submodulesRobert Hensing2020-01-12
|\ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / |/| | | | | | | | | lib/types: Allow paths as submodule values
| * | | | | | | | | lib/types: Allow paths as submodule valuesSilvan Mosberger2020-01-08
| | |_|_|_|_|/ / / | |/| | | | | | |
* | | | | | | | | lib/modules: Switch _module.args from attrsOf to lazyAttrsOfSilvan Mosberger2020-01-10
| | | | | | | | |
* | | | | | | | | lib/tests: Add tests for attrsOf and lazyAttrsOfSilvan Mosberger2020-01-10
| | | | | | | | |
* | | | | | | | | lib/types: Introduce lazyAttrsOfSilvan Mosberger2020-01-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The standard attrsOf is strict in its *values*, meaning it's impossible to access only one attribute value without evaluating all others as well. lazyAttrsOf is a version that doesn't have that problem, at the expense of conditional definitions not properly working anymore.
* | | | | | | | | lib/types: Add emptyValue attribute to typesSilvan Mosberger2020-01-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-Authored-By: Robert Hensing <roberth@users.noreply.github.com>
* | | | | | | | | lib/modules: Move the isDefined check into mergedValueSilvan Mosberger2020-01-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without this change, accessing `mergedValue` from `mergeDefinitions` in case there are no definitions will throw an error like error: evaluation aborted with the following error message: 'This case should never happen.' This change makes it throw the appropriate error error: The option `foo' is used but not defined. This is fully backwards compatible.
* | | | | | | | | lib/tests: Fix module testsSilvan Mosberger2020-01-10
| |_|_|_|_|_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix the broken test in https://github.com/NixOS/nixpkgs/pull/77416 Apparently hydra uses `nix-build lib/tests/release.nix` to run all tests, where IFD isn't allowed. Fortunately we can get around this with builtins.toFile, which doesn't require IFD, but still can test the properties we want.
* | | | | | | | lib/tests: Add test case for imports from derivationsSilvan Mosberger2020-01-10
| | | | | | | |
* | | | | | | | lib/modules: Fix store importsSilvan Mosberger2020-01-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes imports from the store not being possible, which was caused by https://github.com/NixOS/nixpkgs/pull/76857 E.g. such a case: imports = [ "${home-manager}/nixos" ];
* | | | | | | | Merge pull request #76857 from Infinisil/recursive-disableModulesSilvan Mosberger2020-01-09
|\ \ \ \ \ \ \ \ | |/ / / / / / / |/| | | | | | | Apply `disabledModules` recursively
| * | | | | | | lib/tests: Add tests for recursive disabledModulesSilvan Mosberger2020-01-09
| | | | | | | |
| * | | | | | | lib/modules: Recursive disabledModulesSilvan Mosberger2020-01-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this change, disabledModules applies recursively, meaning if you have a module "foo.nix" with imports = [ ./bar.nix ]; then setting disabledModules = [ "foo.nix" ]; will disable both "foo.nix" and "bar.nix", whereas previously only "foo.nix" would be disabled. This change along with https://github.com/NixOS/nixpkgs/pull/61570 allows modules to be fully disabled even when they have some `mkRenamedOption` imports.
* | | | | | | | Clarify error message of 'assigning to top-level attribute' (#76702)Silvan Mosberger2020-01-08
|\ \ \ \ \ \ \ \ | |_|_|_|_|_|/ / |/| | | | | | | Clarify error message of 'assigning to top-level attribute'
| * | | | | | | lib/modules: clarify error message of 'assigning to top-level attribute'Arnout Engelen2020-01-05
| | |/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If I understand correctly, the problem isn't so much that you're assigning to that top-level attribute, but that the assignment to the attribute (or any child of the attribute) introduces the 'config' object and prevents 'lifting' all settings to a generated 'config' object.
* | | | | | | Merge pull request #77133 from Infinisil/fix-path-checkSilvan Mosberger2020-01-07
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | lib/types: Fix path type check
| * | | | | | | lib/types: Fix path type checkSilvan Mosberger2020-01-06
| | |_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously when this function was called without a value coercible to a string it would throw an error instead of returning false. Now it does. As a result this now allows the use of a type like `either path attrs` without it erroring out when a definition is an attribute set. The warning about there not being a isPath primop was removed because this is not the case anymore, there is builtins.isPath. But also there always was `builtins.typeOf x == "path"` that could've been used instead. However the path type now stands for more than just path types, but absolute paths in general.
* | | | | | | lib/types: warn loaOf is deprecatedrnhmjoj2020-01-06
| | | | | | |
* | | | | | | lib/tests: remove strictly loaOf tests and rebase on attrsOfrnhmjoj2020-01-06
|/ / / / / /
* | | | | | lib/tests: Temporarily disable submodule path testSilvan Mosberger2020-01-03
| | | | | | | | | | | | | | | | | | | | | | | | Until https://github.com/NixOS/nixpkgs/pull/76861 or so is merged
* | | | | | Revert "lib/types: Allow paths as submodule values"Silvan Mosberger2020-01-03
| |/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit eec83d41e3e7d9ad5bc1086198d972d55bab1203. This broke hydra evaluation because with this commit submodule values are allowed to be paths, however the certmgr module uses `either (submodule ...) path` in its type, meaning it already used paths for something else which would now be interpreted as a submodule.
* | | | | Module system improvements for NixOS as a submodule (#75031)Silvan Mosberger2020-01-02
|\ \ \ \ \ | |_|_|/ / |/| | | | Module system improvements for NixOS as a submodule
| * | | | lib/tests: Add submoduleWith testsSilvan Mosberger2020-01-02
| | | | |
| * | | | lib/types: Allow paths as submodule valuesSilvan Mosberger2020-01-02
| | | | |
| * | | | lib/modules: Don't pack submodules speciallySilvan Mosberger2020-01-01
| | | | | | | | | | | | | | | | | | | | | | | | | This has the beneficial side effect of allowing paths to be used as modules in types.{submodule,submoduleWith}
| * | | | lib/types: Add types.submoduleWith for more flexibility than types.submoduleSilvan Mosberger2020-01-01
| | | | |
| * | | | lib/modules: Make unifyModuleSyntax fully idempotentSilvan Mosberger2019-12-05
| | | | | | | | | | | | | | | | | | | | Because why not
| * | | | lib/modules: file -> _file for a more idempotent unifyModuleSyntaxSilvan Mosberger2019-12-05
| |/ / / | | | | | | | | | | | | This will be useful for doing more complicated module evaluations
* | | | Merge branch 'ghcjs-cross-without-cc-19.09' into ghcjs-cross-without-ccJohn Ericson2019-11-25
|\ \ \ \
| * | | | Fix lib testsJohn Ericson2019-11-25
| | | | | | | | | | | | | | | | | | | | js-ghcjs didn't fit in an existing categor.
* | | | | Merge remote-tracking branch 'upstream/master' into ghcjs-cross-without-ccJohn Ericson2019-11-25
|\ \ \ \ \ | |/ / / / |/| / / / | |/ / /
| * | | Merge pull request #72657 from cleverca22/vc4John Ericson2019-11-24
| |\ \ \ | | | | | | | | | | Initial implementation of vc4 cross-compile
| | * | | initial implementation of vc4 cross-compileMichael Bishop2019-11-19
| | | | |
| * | | | Merge remote-tracking branch 'upstream/master' into wrapper-pname-supportJohn Ericson2019-11-24
| |\| | | | | |/ / | |/| |
| | * | Merge remote-tracking branch 'upstream/master' into mingw-mcfthreadsJohn Ericson2019-11-11
| | |\ \
| | | * \ Merge pull request #72727 from oxalica/mips-parseMatthew Bauer2019-11-06
| | | |\ \ | | | | | | | | | | | | lib.systems: handle mips family properly
| | | | * | lib.systems: remove redundant mappingoxalica2019-11-04
| | | | | |
| | | | * | lib.systems: handle mips family properlyoxalica2019-11-03
| | | | | |
| | | * | | Add note: Keep error message in sync with nixos-optionChuck2019-11-04
| | | |/ /