swap applyTemplate arguments
This commit is contained in:
parent
90b56eac6e
commit
90856f19bf
1 changed files with 4 additions and 4 deletions
|
@ -29,7 +29,7 @@ pkgs: src: {extraArgs, entries, templates}: let
|
||||||
else
|
else
|
||||||
_template;
|
_template;
|
||||||
|
|
||||||
applyTemplate = entry: templateFile: let
|
applyTemplate = templateFile: entry: let
|
||||||
templateFn = import templateFile;
|
templateFn = import templateFile;
|
||||||
template = templateFn (args // entry);
|
template = templateFn (args // entry);
|
||||||
in
|
in
|
||||||
|
@ -41,7 +41,7 @@ pkgs: src: {extraArgs, entries, templates}: let
|
||||||
newEntry = template.output // {inherit (entry) file;};
|
newEntry = template.output // {inherit (entry) file;};
|
||||||
foundTemplateFile = findTemplateFile newEntry;
|
foundTemplateFile = findTemplateFile newEntry;
|
||||||
in
|
in
|
||||||
applyTemplate newEntry foundTemplateFile;
|
applyTemplate foundTemplateFile newEntry;
|
||||||
|
|
||||||
replaceSuffix = from: to: string:
|
replaceSuffix = from: to: string:
|
||||||
if !(hasSuffix from string) then
|
if !(hasSuffix from string) then
|
||||||
|
@ -79,10 +79,10 @@ pkgs: src: {extraArgs, entries, templates}: let
|
||||||
entry;
|
entry;
|
||||||
|
|
||||||
processEntryFile = entryFile: let
|
processEntryFile = entryFile: let
|
||||||
entry = getEntry entryFile;
|
|
||||||
foundTemplateFile = findTemplateFile entry;
|
foundTemplateFile = findTemplateFile entry;
|
||||||
|
entry = getEntry entryFile;
|
||||||
in
|
in
|
||||||
applyTemplate entry foundTemplateFile;
|
applyTemplate foundTemplateFile entry;
|
||||||
|
|
||||||
in /*sh*/''
|
in /*sh*/''
|
||||||
${concatMapStrings
|
${concatMapStrings
|
||||||
|
|
Loading…
Reference in a new issue