Evgeny Egorochkin
fcbc4fe9ff
Deprecate lib.zip in favor of lib.zipAttrsWith.
...
Add deprecation trace message.
Nixos has been ported away from lib.zip in d705c0c3a4b84768907ade90b3f420d62db422a2.
2013-08-22 10:06:43 +03:00
Marc Weber
a3f148ce96
Improve option types documentation.
2013-08-22 10:01:27 +03:00
Marc Weber
983c87a1dd
Improve the error message for uniq option type.
2013-08-22 09:50:25 +03:00
Marc Weber
fd803fce60
List should be an alias of listOf, and it should no longer be used.
...
Add deprecation notice to list.
Nixos has already been ported from list to listOf (8b2256686b
).
2013-08-22 09:45:22 +03:00
Marc Weber
b00d824930
Drop inferred, because "it was supposed to be used at every location
...
which has no type" according to pierron - but isn't used in
nixos/nixpkgs
2013-08-22 09:37:20 +03:00
Eelco Dolstra
e4ce304333
types.nix: Add a ‘lines’ type
...
This is like types.string, but values are merged by putting a newline
in between them. This is mostly useful for configuration file
options, where we don't want values accidentally ending up on the same
line.
Note that almost all options with string type in NixOS should either
be unmergable (i.e. should be marked with ‘types.uniq’) or should
actually be of type ‘lines’. So it might make sense to remove the
merge function for the ‘string’ type eventually.
2013-02-11 15:32:24 +01:00
Shea Levy
c1598d167e
Simplify lib.typeOf
2012-12-31 13:59:30 -05:00
Shea Levy
2eb0c6fba5
D'oh
2012-12-20 00:52:51 -05:00
Shea Levy
95679e1344
Misunderstood hasOptions, I think
2012-12-20 00:28:12 -05:00
Shea Levy
ce6d4070a6
Add a 'functionTo x' type.
...
This is mainly to for the 'merge' concept, but I made a guess as to what
iter and fold would mean for functions.
2012-12-19 22:49:37 -05:00
Eelco Dolstra
c0a483632c
Eliminate some calls to ‘tail’
2012-08-13 15:15:16 -04:00
Eelco Dolstra
46dc120270
Fix the "path" option type
...
Comparing a string with a context with "/" doesn't work because the
"==" operator also compares context. So the context needs to be
discarded.
2012-07-12 11:54:05 -04:00
Eelco Dolstra
040cf06388
* Add a type "path".
...
svn path=/nixpkgs/trunk/; revision=34247
2012-05-25 17:19:07 +00:00
Eelco Dolstra
bcffafa65a
* Whitespace.
...
svn path=/nixpkgs/trunk/; revision=30044
2011-10-26 17:58:53 +00:00
Nicolas Pierron
6cb018fe90
Add a new type to handle list and attribute sets.
...
List elements are attributed a unique name.
svn path=/nixpkgs/trunk/; revision=27449
2011-06-14 02:41:13 +00:00
Nicolas Pierron
3770ac23aa
Fix type name of attribute sets.
...
svn path=/nixpkgs/trunk/; revision=27011
2011-04-27 18:41:27 +00:00
Nicolas Pierron
56ed820f84
Add systems.nix give more control over the increasing list of supported
...
systems. This is not yet used because it has to be integrated with the
current system.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18468
2009-11-19 17:19:39 +00:00
Nicolas Pierron
8b47086b85
* Change the check function to accept sub-modules with arguments in
...
option definitions.
svn path=/nixpkgs/trunk/; revision=18252
2009-11-07 12:15:39 +00:00
Nicolas Pierron
10d74af2f6
* Add a type to handle environment variables with the usual string
...
separator ":".
svn path=/nixpkgs/trunk/; revision=18239
2009-11-07 01:58:56 +00:00
Nicolas Pierron
d8bbae877a
* Add a type for read-only options. Options which are only declared
...
are used when a module produces read-only data for other modules.
svn path=/nixpkgs/trunk/; revision=18148
2009-11-05 15:39:45 +00:00
Nicolas Pierron
03eab95618
Only allow properties with a onGlobalEval function to go through specific
...
types.
svn path=/nixpkgs/trunk/; revision=17756
2009-10-12 13:37:00 +00:00
Nicolas Pierron
926f20a1ee
Revert "* Revert the last two commits ..." (rev 17738) & Fix.
...
svn path=/nixpkgs/trunk/; revision=17740
2009-10-09 23:03:24 +00:00
Eelco Dolstra
24b50e92ee
* Revert the last two commits since they break every job in the
...
buildfarm ("undefined variable `delayPropertiesTemplate'").
svn path=/nixpkgs/trunk/; revision=17738
2009-10-09 19:34:28 +00:00
Nicolas Pierron
bb16a7f08d
Replace a counter intuitive behaviour of module evaluations.
...
- types.nix:
Introduce a new flag named "delayProperties" which define either that
properties should be evaluated (when false) or that they should be delaied
through the type structure.
- properties.nix:
Generalized the delayProperties function to make it work with the iter
functions of option types.
- modules.nix:
Replace evalProperties by a condition based on the value of the
"delayProperties" flag of the option type. If the flag does not exists or
if it is false, then the system behaves as always. Otherwise it delays
the properties from the current value to each values contained inside it.
svn path=/nixpkgs/trunk/; revision=17736
2009-10-09 18:11:30 +00:00
Nicolas Pierron
ba09982edb
Fix merge function of types.
...
svn path=/nixpkgs/trunk/; revision=17649
2009-10-05 18:10:42 +00:00
Nicolas Pierron
dc8f469349
Fix the merge function of the "attrsOf" type: handle multiple of the same
...
attribute name.
svn path=/nixpkgs/trunk/; revision=17297
2009-09-20 10:29:06 +00:00
Eelco Dolstra
10c4ec0ed8
svn path=/nixpkgs/trunk/; revision=16412
2009-07-17 12:04:34 +00:00
Eelco Dolstra
a440fba8e3
* Refactoring: move the types out of options.nix, which is much too
...
big. Also, they could be useful beyond option handling.
svn path=/nixpkgs/trunk/; revision=16055
2009-06-26 13:53:31 +00:00