Write a string to a file, creating or truncating it.
Declared in <mrdocs/Support/Filesystem/Path.hpp>
Expected<void>
writeFileText(
std::string_view pathName,
std::string_view text);
The path is UTF-8 on every platform, and the bytes of text are written unchanged.
Nothing on success, or an error naming the path if the file could not be opened or written.
| Name | Description |
|---|---|
| pathName | The absolute or relative path to the file. |
| text | The contents to write. |