mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-25 23:36:16 +02:00
Rename large-path-warning-threshold -> warn-large-path-threshold
This commit is contained in:
parent
7f5b57d18f
commit
deac00c6d0
2 changed files with 4 additions and 4 deletions
|
@ -1263,10 +1263,10 @@ public:
|
|||
)"
|
||||
};
|
||||
|
||||
Setting<uint64_t> largePathWarningThreshold{
|
||||
Setting<uint64_t> warnLargePathThreshold{
|
||||
this,
|
||||
std::numeric_limits<uint64_t>::max(),
|
||||
"large-path-warning-threshold",
|
||||
"warn-large-path-threshold",
|
||||
R"(
|
||||
Warn when copying a path larger than this number of bytes to the Nix store
|
||||
(as determined by its NAR serialisation).
|
||||
|
|
|
@ -168,7 +168,7 @@ std::pair<StorePath, Hash> StoreDirConfig::computeStorePath(
|
|||
PathFilter & filter) const
|
||||
{
|
||||
auto [h, size] = hashPath(path, method.getFileIngestionMethod(), hashAlgo, filter);
|
||||
if (size && *size >= settings.largePathWarningThreshold)
|
||||
if (size && *size >= settings.warnLargePathThreshold)
|
||||
warn("hashed large path '%s' (%s)", path, renderSize(*size));
|
||||
return {
|
||||
makeFixedOutputPathFromCA(
|
||||
|
@ -212,7 +212,7 @@ StorePath Store::addToStore(
|
|||
});
|
||||
LengthSource lengthSource(*source);
|
||||
auto storePath = addToStoreFromDump(lengthSource, name, fsm, method, hashAlgo, references, repair);
|
||||
if (lengthSource.total >= settings.largePathWarningThreshold)
|
||||
if (lengthSource.total >= settings.warnLargePathThreshold)
|
||||
warn("copied large path '%s' to the store (%s)", path, renderSize(lengthSource.total));
|
||||
return storePath;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue