diff options
author | John Ericson <John.Ericson@Obsidian.Systems> | 2023-01-11 16:32:30 -0500 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2023-01-11 19:08:19 -0500 |
commit | 5ba6e5d0d9bed2806ddb59c8a3305b3cb5784d53 (patch) | |
tree | 065e7eccec8a228a4045a434c4d5a1de5aa0cf3b /src/nix/flake.cc | |
parent | 114a6e2b09eda7f23e7776e1cdf77715044e073e (diff) |
Remove default constructor from `OutputsSpec`
This forces us to be explicit.
It also requires to rework how `from_json` works. A `JSON_IMPL` is added
to assist with this.
Diffstat (limited to 'src/nix/flake.cc')
-rw-r--r-- | src/nix/flake.cc | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/nix/flake.cc b/src/nix/flake.cc index 33ce3f401..d16d88ef8 100644 --- a/src/nix/flake.cc +++ b/src/nix/flake.cc @@ -513,8 +513,12 @@ struct CmdFlakeCheck : FlakeCommand auto drvPath = checkDerivation( fmt("%s.%s.%s", name, attr_name, state->symbols[attr2.name]), *attr2.value, attr2.pos); - if (drvPath && attr_name == settings.thisSystem.get()) - drvPaths.push_back(DerivedPath::Built{*drvPath}); + if (drvPath && attr_name == settings.thisSystem.get()) { + drvPaths.push_back(DerivedPath::Built { + .drvPath = *drvPath, + .outputs = OutputsSpec::All { }, + }); + } } } } |