mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-09-11 14:35:30 +03:00
{utils -> lib.strings}.sanitizeDerivationName
This commit is contained in:
parent
6c82d99b79
commit
d15d931bf9
@ -53,7 +53,7 @@
|
||||
// {
|
||||
isOriginal = false;
|
||||
outPath = let
|
||||
sanitizedName = utils.sanitizeDerivationName name;
|
||||
sanitizedName = l.strings.sanitizeDerivationName name;
|
||||
in "${sanitizedName}/${version}/${fetched.name}";
|
||||
}
|
||||
# handle already extracted sources
|
||||
@ -63,7 +63,7 @@
|
||||
// {
|
||||
isOriginal = true;
|
||||
outPath = let
|
||||
sanitizedName = utils.sanitizeDerivationName name;
|
||||
sanitizedName = l.strings.sanitizeDerivationName name;
|
||||
in "${sanitizedName}/${version}/${fetched.original.name}";
|
||||
}
|
||||
# handle path sources
|
||||
@ -219,7 +219,7 @@ in {
|
||||
then
|
||||
utils.extractSource {
|
||||
source = "${FODAllSources}/${FODArgsAll."${name}"."${version}".outPath}";
|
||||
name = dlib.sanitizeDerivationName name;
|
||||
name = l.strings.sanitizeDerivationName name;
|
||||
}
|
||||
else "${FODAllSources}/${FODArgsAll."${name}"."${version}".outPath}"
|
||||
else defaultFetched."${name}"."${version}")
|
||||
|
@ -26,7 +26,6 @@
|
||||
recursiveUpdateUntilDepth
|
||||
simpleTranslate2
|
||||
translators
|
||||
sanitizeDerivationName
|
||||
sanitizePath
|
||||
sanitizeRelativePath
|
||||
subsystems
|
||||
@ -280,9 +279,6 @@
|
||||
recursiveUpdateUntilDepth = depth: lhs: rhs:
|
||||
lib.recursiveUpdateUntil (path: _: _: (l.length path) > depth) lhs rhs;
|
||||
|
||||
sanitizeDerivationName = name:
|
||||
lib.replaceStrings ["@" "/"] ["__at__" "__slash__"] name;
|
||||
|
||||
sanitizeRelativePath = path:
|
||||
l.removePrefix "/" (l.toString (l.toPath "/${path}"));
|
||||
|
||||
|
@ -117,7 +117,7 @@ in {
|
||||
# Generates a derivation for a specific package name + version
|
||||
makeOnePackage = name: version: let
|
||||
pkg = compiler.mkDerivation (rec {
|
||||
pname = utils.sanitizeDerivationName name;
|
||||
pname = l.strings.sanitizeDerivationName name;
|
||||
inherit version;
|
||||
license = null;
|
||||
|
||||
|
@ -65,7 +65,6 @@ in
|
||||
parseGitUrl
|
||||
readTextFile
|
||||
recursiveUpdateUntilDepth
|
||||
sanitizeDerivationName
|
||||
traceJ
|
||||
;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user