1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-30 14:10:59 +01:00

* Store user environment manifests as a Nix expression in

$out/manifest.nix rather than as an ATerm.

  (Hm, I thought I committed this two days ago...)
This commit is contained in:
Eelco Dolstra 2010-04-21 15:08:58 +00:00
parent f3b8833a48
commit fe2d869e04
11 changed files with 205 additions and 183 deletions

View file

@ -130,6 +130,20 @@ void switchLink(Path link, Path target)
throw SysError(format("renaming `%1%' to `%2%'") % tmp % link);
}
void lockProfile(PathLocks & lock, const Path & profile)
{
lock.lockPaths(singleton<PathSet>(profile),
(format("waiting for lock on profile `%1%'") % profile).str());
lock.setDeletion(true);
}
string optimisticLockProfile(const Path & profile)
{
return pathExists(profile) ? readLink(profile) : "";
}
}