mirror of
https://github.com/NixOS/nix
synced 2025-06-26 20:01:15 +02:00
Add option to disable import-from-derivation completely, even if the drv is already realized
This commit is contained in:
parent
121a407eec
commit
93f863be96
3 changed files with 7 additions and 0 deletions
|
@ -59,6 +59,8 @@ void EvalState::realiseContext(const PathSet & context)
|
|||
drvs.insert(decoded.first + "!" + decoded.second);
|
||||
}
|
||||
if (!drvs.empty()) {
|
||||
if (!settings.enableImportFromDerivation)
|
||||
throw EvalError(format("attempted to realize ‘%1%’ during evaluation but 'allow-import-from-derivation' is false") % *(drvs.begin()));
|
||||
/* For performance, prefetch all substitute info. */
|
||||
PathSet willBuild, willSubstitute, unknown;
|
||||
unsigned long long downloadSize, narSize;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue