diff options
author | Profpatsch <mail@profpatsch.de> | 2016-04-23 17:55:20 +0200 |
---|---|---|
committer | Profpatsch <mail@profpatsch.de> | 2016-04-23 21:41:35 +0200 |
commit | a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae (patch) | |
tree | 6f5e4e26bc494a1235f38b0cf3463fc0ac09c425 /pkgs | |
parent | 77fa336849704071d068ecc199e6fbbbb85d9546 (diff) | |
download | nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.tar nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.tar.gz nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.tar.bz2 nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.tar.lz nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.tar.xz nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.tar.zst nixlib-a2d38bc7fc271ca5452ec3fd057bca3f737aa9ae.zip |
doc/stdenv.xml document substitution env variables
The filtering of environment variables that start with an uppercase letter is documented in the manual.
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/build-support/substitute/substitute-all.nix | 1 | ||||
-rw-r--r-- | pkgs/stdenv/generic/setup.sh | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/pkgs/build-support/substitute/substitute-all.nix b/pkgs/build-support/substitute/substitute-all.nix index fb26894661d9..1022b25c4c9b 100644 --- a/pkgs/build-support/substitute/substitute-all.nix +++ b/pkgs/build-support/substitute/substitute-all.nix @@ -2,6 +2,7 @@ args: +# see the substituteAll in the nixpkgs documentation for usage and constaints stdenv.mkDerivation ({ name = if args ? name then args.name else baseNameOf (toString args.src); builder = ./substitute-all.sh; diff --git a/pkgs/stdenv/generic/setup.sh b/pkgs/stdenv/generic/setup.sh index f7f9cd533c1f..a183aabed0e3 100644 --- a/pkgs/stdenv/generic/setup.sh +++ b/pkgs/stdenv/generic/setup.sh @@ -445,7 +445,7 @@ substituteAll() { # Select all environment variables that start with a lowercase character. # Will not work with nix attribute names (and thus env variables) containing '\n'. - for envVar in $(env | sed -e $'s/^\([a-z][^=]*\)=.*/\\1/; t \n d'); do + for envVar in $(set | sed -e $'s/^\([a-z][^=]*\)=.*/\\1/; t \n d'); do if [ "$NIX_DEBUG" = "1" ]; then echo "$envVar -> ${!envVar}" fi |