mirror of
https://github.com/NixOS/nix.git
synced 2025-11-14 14:32:42 +01:00
Update src/libexpr/paths.cc
This commit is contained in:
parent
3e45b40d66
commit
7a450a8ba9
1 changed files with 4 additions and 3 deletions
|
|
@ -57,9 +57,10 @@ std::string EvalState::computeBaseName(const SourcePath & path, PosIdx pos)
|
||||||
if (path.accessor == rootFS) {
|
if (path.accessor == rootFS) {
|
||||||
if (auto storePath = store->maybeParseStorePath(path.path.abs())) {
|
if (auto storePath = store->maybeParseStorePath(path.path.abs())) {
|
||||||
warn(
|
warn(
|
||||||
"Performing inefficient double copy of path '%s' to the store at %s. "
|
"Copying '%s' to the store again\n"
|
||||||
"This can typically be avoided by rewriting an attribute like `src = ./.` "
|
"You can make Nix evaluate faster and copy fewer files by replacing `./.` with the `self` flake input, "
|
||||||
"to `src = builtins.path { path = ./.; name = \"source\"; }`.",
|
"or `builtins.path { path = ./.; name = \"source\"; }`\n\n"
|
||||||
|
"Location: %s\n",
|
||||||
path,
|
path,
|
||||||
positions[pos]);
|
positions[pos]);
|
||||||
return std::string(fetchToStore(*store, path, FetchMode::DryRun, storePath->name()).to_string());
|
return std::string(fetchToStore(*store, path, FetchMode::DryRun, storePath->name()).to_string());
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue