mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-11-11 10:16:01 +01:00
runCommandNoCC has been renamed to runCommand and the former has recently been turned into a throw.
14 lines
268 B
Nix
14 lines
268 B
Nix
{
|
|
pkgs ? import <nixpkgs> { },
|
|
feature,
|
|
}:
|
|
|
|
pkgs.runCommand "${feature}-not-present" { } ''
|
|
if [[ -e /${feature}-files ]]; then
|
|
echo "No ${feature} in requiredSystemFeatures, but /${feature}-files was mounted anyway"
|
|
exit 1
|
|
else
|
|
touch $out
|
|
fi
|
|
''
|