write via temp file
This commit is contained in:
parent
3989ad91e6
commit
92d5452a19
1 changed files with 2 additions and 1 deletions
|
@ -27,6 +27,7 @@ import Types.ScheduledActivity
|
||||||
import qualified Annex.Branch
|
import qualified Annex.Branch
|
||||||
import Logs
|
import Logs
|
||||||
import Logs.UUIDBased
|
import Logs.UUIDBased
|
||||||
|
import Utility.Tmp
|
||||||
|
|
||||||
scheduleSet :: UUID -> [ScheduledActivity] -> Annex ()
|
scheduleSet :: UUID -> [ScheduledActivity] -> Annex ()
|
||||||
scheduleSet uuid@(UUID _) activities = do
|
scheduleSet uuid@(UUID _) activities = do
|
||||||
|
@ -67,5 +68,5 @@ getLastRunTimes = do
|
||||||
setLastRunTime :: ScheduledActivity -> LocalTime -> Annex ()
|
setLastRunTime :: ScheduledActivity -> LocalTime -> Annex ()
|
||||||
setLastRunTime activity lastrun = do
|
setLastRunTime activity lastrun = do
|
||||||
f <- fromRepo gitAnnexScheduleState
|
f <- fromRepo gitAnnexScheduleState
|
||||||
liftIO . writeFile f . show . M.insert activity lastrun
|
liftIO . viaTmp writeFile f . show . M.insert activity lastrun
|
||||||
=<< getLastRunTimes
|
=<< getLastRunTimes
|
||||||
|
|
Loading…
Reference in a new issue