1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-07 10:11:47 +02:00

Merge pull request #4842 from NixOS/ca/fix-nix-shell

Make `nix-shell` support content-addressed derivations
This commit is contained in:
Eelco Dolstra 2021-06-23 11:26:22 +02:00 committed by GitHub
commit 7945055c63
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 41 additions and 6 deletions

View file

@ -387,6 +387,12 @@ static void main_nix_build(int argc, char * * argv)
if (dryRun) return;
if (settings.isExperimentalFeatureEnabled("ca-derivations")) {
auto resolvedDrv = drv.tryResolve(*store);
assert(resolvedDrv && "Successfully resolved the derivation");
drv = *resolvedDrv;
}
// Set the environment.
auto env = getEnv();