mirror of
https://github.com/NixOS/nix
synced 2025-07-06 21:41:48 +02:00
Allow passing attributes via files instead of environment variables
Closes #473.
This commit is contained in:
parent
29e1ff675b
commit
a70d275f3d
4 changed files with 55 additions and 5 deletions
|
@ -242,6 +242,27 @@ stdenv.mkDerivation {
|
|||
</varlistentry>
|
||||
|
||||
|
||||
<varlistentry><term><varname>passAsFile</varname></term>
|
||||
|
||||
<listitem><para>A list of names of attributes that should be
|
||||
passed via files rather than environment variables. For example,
|
||||
if you have
|
||||
|
||||
<programlisting>
|
||||
passAsFile = ["big"];
|
||||
big = "a very long string";
|
||||
</programlisting>
|
||||
|
||||
then when the builder runs, the environment variable
|
||||
<envar>big</envar> will contain the absolute path to a temporary
|
||||
file containing <literal>a very long string</literal>. This is
|
||||
useful when you need to pass large strings to a builder, since
|
||||
most operating systems impose a limit on the size of the
|
||||
environment (typically, a few hundred kilobyte).</para></listitem>
|
||||
|
||||
</varlistentry>
|
||||
|
||||
|
||||
<varlistentry><term><varname>preferLocalBuild</varname></term>
|
||||
|
||||
<listitem><para>If this attribute is set to
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue