!7 module DailyBackup > DynEnabled { S sendToMachines; visualize { ret centerAndSouthWithMargins(super.visualize(), withLabel("Send to machines:", dm_fieldTextField('sendToMachines))); } start { doEvery(60.0, 10*60.0, r doIt); } void doIt enter { if (!enabled || elapsedHours_timestamp(parseLongOpt(loadProgramTextFile("lastBackup"))) < 23.99) ret; saveProgramTextFile("lastBackup", str(now())); dm_action("Backing up JavaX-Data", r { final File f = zipAllDataDirs(); if (emptyAfterTrim(sendToMachines)) ret; dm_action("Sending backup to other machines", r { for (S computerID : possibleComputerIDs(javaTokC(sendToMachines))) pcall { dm_sendBackupFileToOtherMachine(f, computerID); } }); }); } }