void writeToFile(String file, String result) { final out = File(file); createFolder(p.dirname(file)); out.writeAsStringSync(result); }