* New query `nix --query --predecessors' to print the predecessors of
a Nix expression.
This commit is contained in:
parent
0abe185688
commit
1d61e473c8
5 changed files with 29 additions and 2 deletions
|
|
@ -104,6 +104,14 @@ void registerSuccessor(const Transaction & txn,
|
|||
}
|
||||
|
||||
|
||||
Paths queryPredecessors(const Path & sucPath)
|
||||
{
|
||||
Paths revs;
|
||||
nixDB.queryStrings(noTxn, dbSuccessorsRev, sucPath, revs);
|
||||
return revs;
|
||||
}
|
||||
|
||||
|
||||
void registerSubstitute(const Path & srcPath, const Path & subPath)
|
||||
{
|
||||
Transaction txn(nixDB);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue