2017-03-30 23:03:40 +03:00
|
|
|
/* Library of low-level helper functions for nix expressions.
|
|
|
|
*
|
|
|
|
* Please implement (mostly) exhaustive unit tests
|
|
|
|
* for new functions in `./tests.nix'.
|
|
|
|
*/
|
2016-09-15 02:21:42 +03:00
|
|
|
let
|
2006-09-25 14:07:59 +04:00
|
|
|
|
2017-05-30 01:09:52 +03:00
|
|
|
# often used, or depending on very little
|
2009-02-09 19:51:03 +03:00
|
|
|
trivial = import ./trivial.nix;
|
2017-05-30 01:09:52 +03:00
|
|
|
fixedPoints = import ./fixed-points.nix;
|
2016-09-15 02:21:42 +03:00
|
|
|
|
|
|
|
# datatypes
|
|
|
|
attrsets = import ./attrsets.nix;
|
2009-02-09 19:51:03 +03:00
|
|
|
lists = import ./lists.nix;
|
|
|
|
strings = import ./strings.nix;
|
2009-05-25 22:22:19 +04:00
|
|
|
stringsWithDeps = import ./strings-with-deps.nix;
|
2016-09-15 02:21:42 +03:00
|
|
|
|
|
|
|
# packaging
|
|
|
|
customisation = import ./customisation.nix;
|
|
|
|
maintainers = import ./maintainers.nix;
|
|
|
|
meta = import ./meta.nix;
|
2009-02-09 19:51:03 +03:00
|
|
|
sources = import ./sources.nix;
|
2016-09-15 02:21:42 +03:00
|
|
|
|
|
|
|
# module system
|
2009-07-13 20:18:52 +04:00
|
|
|
modules = import ./modules.nix;
|
2009-02-09 19:51:03 +03:00
|
|
|
options = import ./options.nix;
|
2009-06-26 17:53:31 +04:00
|
|
|
types = import ./types.nix;
|
2016-09-15 02:21:42 +03:00
|
|
|
|
|
|
|
# constants
|
|
|
|
licenses = import ./licenses.nix;
|
2017-02-09 05:27:22 +03:00
|
|
|
systems = import ./systems;
|
2016-09-15 02:21:42 +03:00
|
|
|
|
|
|
|
# misc
|
|
|
|
debug = import ./debug.nix;
|
2016-11-06 03:51:13 +03:00
|
|
|
generators = import ./generators.nix;
|
2016-09-15 02:21:42 +03:00
|
|
|
misc = import ./deprecated.nix;
|
|
|
|
|
|
|
|
# domain-specific
|
2015-11-19 22:33:21 +03:00
|
|
|
sandbox = import ./sandbox.nix;
|
2016-09-17 22:50:01 +03:00
|
|
|
fetchers = import ./fetchers.nix;
|
2006-11-27 19:58:08 +03:00
|
|
|
|
2017-03-04 21:15:23 +03:00
|
|
|
# Eval-time filesystem handling
|
|
|
|
filesystem = import ./filesystem.nix;
|
|
|
|
|
2006-11-27 19:58:08 +03:00
|
|
|
in
|
2017-05-30 01:09:52 +03:00
|
|
|
{ inherit trivial fixedPoints
|
2016-09-15 02:21:42 +03:00
|
|
|
attrsets lists strings stringsWithDeps
|
|
|
|
customisation maintainers meta sources
|
|
|
|
modules options types
|
2017-02-09 05:27:22 +03:00
|
|
|
licenses systems
|
2016-11-06 03:51:13 +03:00
|
|
|
debug generators misc
|
2017-03-04 21:15:23 +03:00
|
|
|
sandbox fetchers filesystem;
|
2017-02-09 05:27:22 +03:00
|
|
|
|
|
|
|
# back-compat aliases
|
|
|
|
platforms = systems.doubles;
|
2009-07-01 19:38:55 +04:00
|
|
|
}
|
2009-02-09 19:51:03 +03:00
|
|
|
# !!! don't include everything at top-level; perhaps only the most
|
|
|
|
# commonly used functions.
|
2017-05-30 01:09:52 +03:00
|
|
|
// trivial // fixedPoints
|
|
|
|
// lists // strings // stringsWithDeps // attrsets // sources
|
2013-10-28 03:56:22 +04:00
|
|
|
// options // types // meta // debug // misc // modules
|
2009-11-19 19:43:58 +03:00
|
|
|
// customisation
|