Restore file's modification time in git

Posted by rampion on Stack Overflow See other posts from Stack Overflow or by rampion
Published on 2010-03-16T20:51:31Z Indexed on 2010/03/16 21:11 UTC
Read the original article Hit count: 219

Filed under:

I understand the default git behaviour of updating the modification time every time it changes a file, but there are times when I want to restore a file's original modification time.

Is there a way I can tell git to do this?

(As an example, when working on a large project, I made some changes to configure.ac, found out that autotools doesn't work on my system, and wanted to restore configure.ac's to its original contents and modification time so that make doesn't try to update configure with my broken autotools).

© Stack Overflow or respective owner

Related posts about git