1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-06-09 09:36:20 +09:00

doc: fix various nix snippets

This commit is contained in:
Pol Dellaiera 2025-04-08 17:36:13 +02:00 committed by Valentin Gagarin
parent 58cdd4e315
commit 5d979e79ce
10 changed files with 64 additions and 30 deletions

View file

@ -20,13 +20,15 @@ stdenv.mkDerivation {
If you use a custom `checkPhase`, remember to add the `runHook` calls:
```nix
checkPhase ''
{
checkPhase = ''
runHook preCheck
# ... your tests
runHook postCheck
''
'';
}
```
## Variables {#sec-memcachedTestHook-variables}
@ -48,6 +50,6 @@ stdenv.mkDerivation {
];
preCheck = ''
memcachedTestPort=1234
''
memcachedTestPort=1234;
'';
}

View file

@ -21,13 +21,15 @@ stdenv.mkDerivation {
If you use a custom `checkPhase`, remember to add the `runHook` calls:
```nix
checkPhase ''
{
checkPhase = ''
runHook preCheck
# ... your tests
runHook postCheck
''
'';
}
```
## Variables {#sec-redisTestHook-variables}
@ -55,6 +57,6 @@ stdenv.mkDerivation {
];
preCheck = ''
redisTestPort=6390
''
redisTestPort=6390;
'';
}