nix/develop: Set default outputs attribute

When using `builtins.derivation`, the `outputs` list can be omitted, and
in that case, it defaults to `[ "out" ]`, set this default when building
the shell derivation for `nix develop`

Fixes: #556
Change-Id: I4dc77d060f30ee499e186ec919de30bd3e5c53bb
This commit is contained in:
Tom Hubrecht
2025-11-24 09:56:14 +00:00
parent 395fe68127
commit 26de2b79c2
+4
View File
@@ -257,6 +257,10 @@ try {
output.second = DerivationOutput::InputAddressed { .path = StorePath::dummy };
drv.env[output.first] = "";
}
// outputs default to [ "out" ]
drv.env.try_emplace("outputs", "out");
auto hashesModulo = TRY_AWAIT(hashDerivationModulo(*evalStore, drv, true));
for (auto & output : drv.outputs) {