Make files.renameDirAlmostAtomically() retry a number of times before giving up.