loadBuildHistory method
Loads recorded build history, newest first. Returns an empty list if no history file exists yet.
Implementation
Future<List<Map<String, dynamic>>> loadBuildHistory() async {
final file = File(_historyFilePath);
if (!file.existsSync()) return [];
try {
final content = await file.readAsString();
final decoded = jsonDecode(content) as List<dynamic>;
return decoded.cast<Map<String, dynamic>>();
} catch (e) {
Logger.warning('Failed to read build history: $e');
return [];
}
}