forked from lix-project/lix
flake.nixConfig: fix flake-registry config settings
Before this commit, nixConfig.flake-registry didn't have any real effect on the evaluation, since config was applied after inputs were evaluated. Change this behavior: apply the config in the beginning of flake::lockFile.
This commit is contained in:
parent
69eb65403a
commit
ef1e7ab840
|
@ -575,8 +575,6 @@ std::shared_ptr<flake::LockedFlake> InstallableFlake::getLockedFlake() const
|
||||||
{
|
{
|
||||||
if (!_lockedFlake) {
|
if (!_lockedFlake) {
|
||||||
_lockedFlake = std::make_shared<flake::LockedFlake>(lockFlake(*state, flakeRef, lockFlags));
|
_lockedFlake = std::make_shared<flake::LockedFlake>(lockFlake(*state, flakeRef, lockFlags));
|
||||||
_lockedFlake->flake.config.apply();
|
|
||||||
// FIXME: send new config to the daemon.
|
|
||||||
}
|
}
|
||||||
return _lockedFlake;
|
return _lockedFlake;
|
||||||
}
|
}
|
||||||
|
|
|
@ -298,6 +298,9 @@ LockedFlake lockFlake(
|
||||||
|
|
||||||
auto flake = getFlake(state, topRef, lockFlags.useRegistries, flakeCache);
|
auto flake = getFlake(state, topRef, lockFlags.useRegistries, flakeCache);
|
||||||
|
|
||||||
|
flake.config.apply();
|
||||||
|
// FIXME: send new config to the daemon.
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
// FIXME: symlink attack
|
// FIXME: symlink attack
|
||||||
|
|
Loading…
Reference in a new issue