* @brief Copies the contents of a file to another file. * * @param srcFilePath The source file path. * @param dstFilePath The destination file path. * @return true if the file was copied successfully, false otherwise. */
| 353 | * @return true if the file was copied successfully, false otherwise. |
| 354 | */ |
| 355 | inline static bool copy(const std::string &srcFilePath, const std::string &dstFilePath) |
| 356 | { |
| 357 | KittyIOFile f(srcFilePath, O_RDONLY | O_CLOEXEC); |
| 358 | return f.open() && f.writeToFile(dstFilePath); |
| 359 | } |
| 360 | |
| 361 | /** |
| 362 | * @brief Lists files in a directory. |
nothing calls this directly
no test coverage detected