mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-10 19:55:41 +03:00
doc/build-helpers: add note relating runCommand
and runCommandWith
This commit is contained in:
parent
482d6eaab2
commit
e3d7e7f2a7
1 changed files with 18 additions and 0 deletions
|
@ -126,6 +126,24 @@ runCommand "my-example" {} ''
|
|||
```
|
||||
:::
|
||||
|
||||
::: {.note}
|
||||
`runCommand name derivationArgs buildCommand` is equivalent to
|
||||
```nix
|
||||
runCommandWith {
|
||||
inherit name derivationArgs;
|
||||
stdenv = stdenvNoCC;
|
||||
} buildCommand
|
||||
```
|
||||
|
||||
Likewise, `runCommandCC name derivationArgs buildCommand` is equivalent to
|
||||
```nix
|
||||
runCommandWith {
|
||||
inherit name derivationArgs;
|
||||
} buildCommand
|
||||
```
|
||||
:::
|
||||
|
||||
|
||||
## `runCommandLocal` {#trivial-builder-runCommandLocal}
|
||||
|
||||
Variant of `runCommand` that forces the derivation to be built locally, it is not substituted. This is intended for very cheap commands (<1s execution time). It saves on the network round-trip and can speed up a build.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue