Work in Progress
Environment variables should go to env
Currently, the attributes passed to stdenv.mkDerivation
serve two purposes:
- controlling stdenv
- setting environment variables
This RFC intends to untangle this situation by relegating the setting of environment variables to a dedicated env
attribute set.
env
attribute
- Ability to better detect typos
- Nicer structured attributes
- Theoretical purity
- Add support for
env
tomkDerivation
. The content would be passed back toderivation
. - Move known environment attributes (nixpkgs-hammering has a list) to
env
(can be done semi-programmatically) and random attributes using recursive attrsets instead oflet
s intolet
s. Only stdenv options should remain. - Make
stdenv
take closed pattern as an argument. ¿TODO: How to deal with setup hooks that introduce extra parameters?
- status quo