Reputation: 2128
I've created a repo for our website. The initial commit touched file modification dates so all dates show the commit date.
In a later time, I downloaded the unmodified files from the web server to my WC so old unmodified files have their original dates now as in the web server and I can sync my local copy with the production and test servers during a deployment.
Now I noticed the issue with the dates in the repo, and I wish to make it so the file modification dates in the repo get same with my working copy. Is there a method so I can commit file properties of unmodified files?
Upvotes: 4
Views: 3198
Reputation: 29707
Subversion doesn't have this capability because the creators didn't think that it was important. Subversion only considers a file's name, contents, execute permission, but not this part of file metadata.
It's unfortunate, many users (including me) use subversion as a file synchronization system, and it's useful to synchronize modification times.
EDIT FROM 10 YEARS LATER: I no longer use Subversion for file synchronization.
Upvotes: 1
Reputation: 16779
You can't use svn and care about dates. Must pick one of them.
Having said that there is one option in TortoiseSVN > Settings > General > Set file dates to the "last commit time"
. This yields the date of commit, but not the date of last change.
To have the date of last change you must fiddle with commit hooks. TortoiseSVN > Settings > Hook Scripts
. The only script I ever used is the one that allows the change of the log, so can't help you with that. See following questions for more info:
Apparently you can't set the dates of individual files, but you can set the date of the revision. The name of the property is svn:date
, and I have a feeling that there may be some side effects of changing it. So, be warned.
Upvotes: 5