Skip to content

Commit

Permalink
Don't try to change timestamps if we are dry-run.
Browse files Browse the repository at this point in the history
  • Loading branch information
Guy Coates committed Nov 27, 2014
1 parent 32ee78a commit 501e8b1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pcp
Original file line number Diff line number Diff line change
Expand Up @@ -1187,7 +1187,8 @@ class fixtimestamp(parallelwalk.ParallelWalk):
def ProcessDir(self, directoryname):
stat = safestat(directoryname)
newdir = mungePath(sourcedir, destdir, directoryname)
os.utime(newdir, (stat.st_atime, stat.st_mtime))
if not DRYRUN:
os.utime(newdir, (stat.st_atime, stat.st_mtime))

class MPIargparse(argparse.ArgumentParser):
"""Subclass argparse so we can add a call to Abort, to tidy up MPI bits and pieces."""
Expand Down

0 comments on commit 501e8b1

Please sign in to comment.