mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-10 08:16:15 +02:00
Don't say "copying X to the store" in read-only mode
This commit is contained in:
parent
06be819b89
commit
6162105675
1 changed files with 5 additions and 2 deletions
|
@ -33,12 +33,15 @@ StorePath fetchToStore(
|
|||
} else
|
||||
debug("source path '%s' is uncacheable", path);
|
||||
|
||||
Activity act(*logger, lvlChatty, actUnknown, fmt("copying '%s' to the store", path));
|
||||
auto readOnly = settings.readOnlyMode;
|
||||
|
||||
Activity act(*logger, lvlChatty, actUnknown,
|
||||
fmt(readOnly ? "hashing '%s'" : "copying '%s' to the store", path));
|
||||
|
||||
auto filter2 = filter ? *filter : defaultPathFilter;
|
||||
|
||||
auto storePath =
|
||||
settings.readOnlyMode
|
||||
readOnly
|
||||
? store.computeStorePath(
|
||||
name, *path.accessor, path.path, method, HashAlgorithm::SHA256, {}, filter2).first
|
||||
: store.addToStore(
|
||||
|
|
Loading…
Reference in a new issue