mirror of
https://github.com/NixOS/nix.git
synced 2025-11-27 12:41:00 +01:00
In the middle of adding state references to derivations and the db...
This commit is contained in:
parent
5e59387d40
commit
bdecf3bdbc
16 changed files with 190 additions and 191 deletions
|
|
@ -27,11 +27,15 @@ Path writeDerivation(const Derivation & drv, const string & name)
|
|||
/* Note that the outputs of a derivation are *not* references
|
||||
(that can be missing (of course) and should not necessarily be
|
||||
held during a garbage collection). */
|
||||
|
||||
//TODO TODO TODO !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
PathSet stateReferences;
|
||||
|
||||
string suffix = name + drvExtension;
|
||||
string contents = atPrint(unparseDerivation(drv));
|
||||
return readOnlyMode
|
||||
? computeStorePathForText(suffix, contents, references)
|
||||
: store->addTextToStore(suffix, contents, references);
|
||||
? computeStorePathForText(suffix, contents, references, stateReferences)
|
||||
: store->addTextToStore(suffix, contents, references, stateReferences);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue