* @brief colect information about the filesystem under a file * */
| 1210 | * |
| 1211 | */ |
| 1212 | FilesystemInfo statFS(const QString& path) |
| 1213 | { |
| 1214 | FilesystemInfo info; |
| 1215 | |
| 1216 | QStorageInfo storage_info(nearestExistentAncestor(path)); |
| 1217 | |
| 1218 | info.fsTypeName = storage_info.fileSystemType(); |
| 1219 | |
| 1220 | info.fsType = getFilesystemTypeFuzzy(info.fsTypeName); |
| 1221 | |
| 1222 | info.blockSize = storage_info.blockSize(); |
| 1223 | info.bytesAvailable = storage_info.bytesAvailable(); |
| 1224 | info.bytesFree = storage_info.bytesFree(); |
| 1225 | info.bytesTotal = storage_info.bytesTotal(); |
| 1226 | |
| 1227 | info.name = storage_info.name(); |
| 1228 | info.rootPath = storage_info.rootPath(); |
| 1229 | |
| 1230 | return info; |
| 1231 | } |
| 1232 | |
| 1233 | /** |
| 1234 | * @brief if the Filesystem is reflink/clone capable |
no test coverage detected