Closed drrlvn closed 5 years ago
Please add set_file_mtime() and set_file_atime() that set only one of the values.
set_file_mtime()
set_file_atime()
In Linux this can be done by passing UTIME_OMIT as the argument that's not needed. See example in libstdc++'s implementation of std::filesystem::last_write_time(): https://github.com/gcc-mirror/gcc/blob/gcc-8_1_0-release/libstdc%2B%2B-v3/src/filesystem/std-ops.cc#L1067
UTIME_OMIT
libstdc++
std::filesystem::last_write_time()
Sounds reasonable to me!
Done in https://github.com/alexcrichton/filetime/pull/40
Please add
set_file_mtime()
andset_file_atime()
that set only one of the values.In Linux this can be done by passing
UTIME_OMIT
as the argument that's not needed. See example inlibstdc++
's implementation ofstd::filesystem::last_write_time()
: https://github.com/gcc-mirror/gcc/blob/gcc-8_1_0-release/libstdc%2B%2B-v3/src/filesystem/std-ops.cc#L1067