mirror of
https://github.com/NixOS/nix.git
synced 2025-11-15 06:52:43 +01:00
Fix emitting narHash in lock files when lazy trees are disabled
This commit is contained in:
parent
9bbe06be3a
commit
4ea5cb3832
3 changed files with 3 additions and 2 deletions
|
|
@ -77,7 +77,7 @@ StorePath EvalState::mountInput(
|
|||
|
||||
storeFS->mount(CanonPath(store->printStorePath(storePath)), accessor);
|
||||
|
||||
if (requireLockable && !input.isLocked() && !input.getNarHash()) {
|
||||
if (requireLockable && (!settings.lazyTrees || !input.isLocked()) && !input.getNarHash()) {
|
||||
auto narHash = accessor->hashPath(CanonPath::root);
|
||||
input.attrs.insert_or_assign("narHash", narHash.to_string(HashFormat::SRI, true));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue