Skip to content

Commit

Permalink
feat(build): #546 propagate inputs
Browse files Browse the repository at this point in the history
- This merges inputs from the flake and make them
  available to scripts under the magic makes/ folder
  as well as to the modules configuration

Relates to #540
  • Loading branch information
kamadorueda committed Sep 17, 2021
1 parent f04f8ae commit 572e2d3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
}:
let
evaluated = import ./src/evaluator/default.nix {
extraInputs = inputs;
# TODO: Deprecate this
makesExecutionId = "123";
makesSrc = inputs.makes.outPath;
Expand Down
6 changes: 4 additions & 2 deletions src/evaluator/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,10 @@
# You better avoid changing this function signature...
# Ask a maintainer first.
{
# extra inputs to inject, if any
extraInputs ? { }
# Unique ID for this execution of makes
makesExecutionId
, makesExecutionId
# Source code of makes, can be overriden by the user.
, makesSrc
# Path to the user's project, inside a sandbox.
Expand Down Expand Up @@ -43,7 +45,7 @@ let
else makesSrc;

args = import "${makesSrcOverriden}/src/args/default.nix" {
inputs = result.config.inputs;
inputs = result.config.inputs // extraInputs;
inherit makesExecutionId;
outputs = result.config.outputs;
inherit projectSrc;
Expand Down

0 comments on commit 572e2d3

Please sign in to comment.