trivial-builders: Sanitize derivation name
This then supports using functions like writeShellScriptBin with script names that would be invalid as derivation names
This commit is contained in:
parent
1c951b1484
commit
c60e559e13
@ -4,7 +4,8 @@ let
|
|||||||
|
|
||||||
runCommand' = runLocal: stdenv: name: env: buildCommand:
|
runCommand' = runLocal: stdenv: name: env: buildCommand:
|
||||||
stdenv.mkDerivation ({
|
stdenv.mkDerivation ({
|
||||||
inherit name buildCommand;
|
name = lib.strings.sanitizeDerivationName name;
|
||||||
|
inherit buildCommand;
|
||||||
passAsFile = [ "buildCommand" ];
|
passAsFile = [ "buildCommand" ];
|
||||||
}
|
}
|
||||||
// (lib.optionalAttrs runLocal {
|
// (lib.optionalAttrs runLocal {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user