reworked developer tools with diagnostics, storage viewers and release-capable debug overlays

This commit is contained in:
2026-09-26 14:34:47 +02:00
parent 0f6c388940
commit e6f74ca6fe
18 changed files with 1330 additions and 239 deletions
+16
View File
@@ -0,0 +1,16 @@
import 'dart:io';
/// Total byte size of all files below [dir]; `0` when it doesn't exist or
/// can't be listed.
Future<int> directorySize(Directory dir) async {
var sum = 0;
try {
if (!dir.existsSync()) return 0;
await for (final entity in dir.list(recursive: true, followLinks: false)) {
if (entity is File) sum += await entity.length();
}
} on FileSystemException {
// Files can vanish mid-walk (cache pruning); report what was counted.
}
return sum;
}