| Commit message (Expand) | Author | Age | Files | Lines |
| * | Replace short URL from #63103 with full URL.•••The error message is already helpfully verbose, so there's little
reason to shorten the informational URL.
| Drew Hess | 2020-01-15 | 1 | -1/+1 |
| * | lib/types: prioritise coercedType in coercedTo•••This more intuitively matches `types.either` and allows paths to be
coerced to submodules again, which was inhibited by #76861
| arcnmx | 2020-01-14 | 1 | -4/+4 |
| * | lib/types: dont warn loaOf for home-manager namespace•••This option namespace is not a part of NixOS
so we shouldn't provide this warning for it.
| worldofpeace | 2020-01-12 | 1 | -12/+0 |
| * | Merge pull request #77501 from jtojnar/more-loaof-fxes•••tree-wide: fix more warning related to loaOf deprecation | Jan Tojnar | 2020-01-12 | 1 | -5/+67 |
| |\ |
|
| | * | lib/types: improve loaOf message even more•••Now we suggest correct names for all options in Nixpkgs and also home-manager at the time of writing.
| Jan Tojnar | 2020-01-11 | 1 | -7/+64 |
| | * | lib/types: only show ... in loaOf warning when necessary | Jan Tojnar | 2020-01-11 | 1 | -2/+3 |
| | * | lib/types: improve loaOf warning•••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.
| Jan Tojnar | 2020-01-11 | 1 | -3/+7 |
| * | | Merge pull request #76861 from Infinisil/paths-as-submodules•••lib/types: Allow paths as submodule values | Robert Hensing | 2020-01-12 | 1 | -3/+5 |
| |\ \
| |/
|/| |
|
| | * | lib/types: Allow paths as submodule values | Silvan Mosberger | 2020-01-08 | 1 | -3/+5 |
| * | | lib/types: Introduce lazyAttrsOf•••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.
| Silvan Mosberger | 2020-01-10 | 1 | -0/+24 |
| * | | lib/types: Add emptyValue attribute to types•••Co-Authored-By: Robert Hensing <roberth@users.noreply.github.com>
| Silvan Mosberger | 2020-01-10 | 1 | -2/+18 |
| |/ |
|
| * | Merge pull request #77133 from Infinisil/fix-path-check•••lib/types: Fix path type check | Silvan Mosberger | 2020-01-07 | 1 | -2/+1 |
| |\ |
|
| | * | lib/types: Fix path type check•••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.
| Silvan Mosberger | 2020-01-06 | 1 | -2/+1 |
| * | | lib/types: warn loaOf is deprecated | rnhmjoj | 2020-01-06 | 1 | -12/+29 |
| |/ |
|
| * | Revert "lib/types: Allow paths as submodule values"•••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.
| Silvan Mosberger | 2020-01-03 | 1 | -5/+3 |
| * | lib/types: Allow paths as submodule values | Silvan Mosberger | 2020-01-02 | 1 | -3/+5 |
| * | lib/types: Add types.submoduleWith for more flexibility than types.submodule | Silvan Mosberger | 2020-01-01 | 1 | -15/+47 |
| * | Merge branch 'master' into staging | Vladimír Čunát | 2019-09-02 | 1 | -1/+2 |
| |\ |
|
| | * | lib/types: Make usage of types.string emit a warning | Silvan Mosberger | 2019-08-31 | 1 | -1/+2 |
| * | | treewide: remove redundant rec | volth | 2019-08-28 | 1 | -3/+3 |
| * | | treewide: remove redundant quotes | volth | 2019-08-26 | 1 | -1/+1 |
| |/ |
|
| * | Merge pull request #65728 from Infinisil/types-eithers•••lib/types: Add oneOf, extension of either to a list of types | Aaron Andersen | 2019-08-13 | 1 | -0/+7 |
| |\ |
|
| | * | lib/types: Add oneOf, extension of either to a list of types | Silvan Mosberger | 2019-08-06 | 1 | -0/+7 |
| * | | lib/types: change merge strategy for `str`, `int`, `float` and `enum`•••Change to `mergeEqualOption`.
| danbst | 2019-07-25 | 1 | -5/+5 |
| |/ |
|
| * | module system: revert "remove types.optionSet", just deprecate (#56857)•••The explicit remove helped to uncover some hidden uses of `optionSet`
in NixOps. However it makes life harder for end-users of NixOps - it will
be impossible to deploy 19.03 systems with old NixOps, but there is no
new release of NixOps with `optionSet` fixes.
Also, "deprecation" process isn't well defined. Even that `optionSet` was
declared "deprecated" for many years, it was never announced. Hence, I
leave "deprecation" announce. Then, 3 releases after announce,
we can announce removal of this feature.
This type has to be removed, not `throw`-ed in runtime, because it makes
some perfectly fine code to fail. For example:
```
$ nix-instantiate --eval -E '(import <nixpkgs/lib>).types' --strict
trace: `types.list` is deprecated; use `types.listOf` instead
error: types.optionSet is deprecated; use types.submodule instead
(use '--show-trace' to show detailed location information)
``` | Danylo Hlynskyi | 2019-03-07 | 1 | -2/+4 |
| * | types.optionSet: deprecate and remove last usages | danbst | 2019-01-31 | 1 | -4/+1 |
| * | lib/types.nix: small eval optimization (listToAttrs + mapAttrsToList -> mapAt... | danbst | 2019-01-30 | 1 | -2/+1 |
| * | Add type port as an alias to u16 | Daniel Rutz | 2018-10-18 | 1 | -0/+3 |
| * | lib/types: enhances separatedString's description•••The previous description "string" is misleading in the full options
manual pages; they are actually concatenated strings, with a specific
character.
The empty string version ("types.string") has been special-cased to
provide a better message.
| Samuel Dionne-Riel | 2018-10-12 | 1 | -1/+4 |
| * | lib: move assertMsg and assertOneOf to their own library file•••Since the `assertOneOf` uses `lib.generators`, they are not really trivial
anymore and should go into their own library file.
| Profpatsch | 2018-09-06 | 1 | -1/+1 |
| * | lib/trivial: add a few examples of usage of assertMsg/assertOneOf | Profpatsch | 2018-09-06 | 1 | -2/+6 |
| * | [bot] treewide: remove unused 'inherit' in let blocks | volth | 2018-07-20 | 1 | -1/+1 |
| * | [bot]: remove unreferenced code | volth | 2018-07-20 | 1 | -1/+0 |
| * | lib: add float option type | Richard Marko | 2018-07-03 | 1 | -0/+7 |
| * | doc: Fixes documented default option for `<name>` for submodules. (#40464)•••Fixes #40463
This is related to change 1d56d0c8a79334cd7149fd580512046558eaac78 | Samuel Dionne-Riel | 2018-05-16 | 1 | -1/+7 |
| * | lib.types: fix loaOf behavior for long lists•••Assigning a list of 10 or more elements to an option having the type
`loaOf a` produces a configuration value that is not honoring the
order of the original list. This commit fixes this and a related issue
arising when 10 or more lists are merged into this type of option.
| Robert Helgesson | 2018-05-07 | 1 | -9/+20 |
| * | lib/types: remove unnecessary coerceFunc assertion | Silvan Mosberger | 2018-05-06 | 1 | -4/+1 |
| * | lib/types: clear up coercedTo description | Silvan Mosberger | 2018-05-06 | 1 | -2/+2 |
| * | lib/types: Fix coercedTo check•••Without this change
(coercedTo str toInt int).check "foo"
would evaluate to true, even though
(coercedTo str toInt int).merge {} [{ value = "foo"; }]
will throw an error because "foo" can't be coerced to an int.
| Silvan Mosberger | 2018-05-06 | 1 | -1/+1 |
| * | lib/types: add types.nonEmptyListOf | Robert Schütz | 2018-02-08 | 1 | -0/+4 |
| * | nixpkgs.lib: Add types.strMatching | Ryan Trinkle | 2017-12-02 | 1 | -0/+7 |
| * | lib/types.nix: Disable 32-bit integer types for now•••This file doesn't evaluate in 32-bit versions of Nix because the integer
type is a signed 32-bit integer there, so 4294967296 causes an 'invalid
integer' error. I see no other way around than commenting this out :(
(s32 could be made to work by tweaking the expressions a bit, but didn't
do that for now since it'd be asymmetric to have s32 but no u32).
| Tuomas Tynkkynen | 2017-11-05 | 1 | -5/+5 |
| * | lib/types: fix up documentation formatting a bit | Profpatsch | 2017-11-05 | 1 | -4/+4 |
| * | lib/types: add `ints.positive`.•••For values that are positive, but cannot be 0.
| Profpatsch | 2017-11-05 | 1 | -0/+4 |
| * | lib/types: match lowercase descriptions of other types | Profpatsch | 2017-11-05 | 1 | -4/+4 |
| * | lib/types: signed -> s, unsigned -> u, remove signed alias•••Mirrors the way it’s done in modern low-level languages like Rust (by input of
@nbp).
Removes the signed alias for int.
| Profpatsch | 2017-11-05 | 1 | -16/+12 |
| * | lib/types: remove port type again•••Will be introduced as a taggedUnion, once that type is in nixpkgs.
| Profpatsch | 2017-11-05 | 1 | -3/+0 |
| * | lib/types: add port type | Profpatsch | 2017-11-05 | 1 | -4/+7 |
| * | lib/types: add various signed/unsigned int types•••It is sometimes necessary to restrict the domain of integers for configurations,
as well as restricting them to unsigned/positive values.
| Profpatsch | 2017-11-05 | 1 | -10/+57 |
| * | lib/types: add intBetween•••An int type that checks the value range.
| Profpatsch | 2017-11-05 | 1 | -0/+6 |