mirror of
https://github.com/NixOS/nix.git
synced 2025-11-11 21:16:02 +01:00
moveFile -> renameFile
`move` tends to have this `mv` connotation of “I will copy it for you if needs be”
This commit is contained in:
parent
a4f0fd633c
commit
d71d9e9fbf
9 changed files with 13 additions and 13 deletions
|
|
@ -37,7 +37,7 @@ void replaceSymlink(const Path & target, const Path & link,
|
|||
throw;
|
||||
}
|
||||
|
||||
moveFile(tmp, link);
|
||||
renameFile(tmp, link);
|
||||
|
||||
break;
|
||||
}
|
||||
|
|
@ -90,7 +90,7 @@ void copy(const fs::directory_entry & from, const fs::path & to, bool andDelete)
|
|||
}
|
||||
}
|
||||
|
||||
void moveFile(const Path & oldName, const Path & newName)
|
||||
void renameFile(const Path & oldName, const Path & newName)
|
||||
{
|
||||
auto oldPath = fs::path(oldName);
|
||||
auto newPath = fs::path(newName);
|
||||
|
|
|
|||
|
|
@ -168,7 +168,7 @@ void createSymlink(const Path & target, const Path & link,
|
|||
void replaceSymlink(const Path & target, const Path & link,
|
||||
std::optional<time_t> mtime = {});
|
||||
|
||||
void moveFile(const Path & src, const Path & dst);
|
||||
void renameFile(const Path & src, const Path & dst);
|
||||
|
||||
|
||||
/* Wrappers arount read()/write() that read/write exactly the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue