[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Is there really no way to keep the file modification time intact?

From: Les Mikesell <lesmikesell_at_gmail.com>
Date: 2007-02-27 20:01:06 CET

Frans Knibbe wrote:

>> I want my files to come back exactly like they were when I
>>
>> Um, no. That's not 'the file', that's 'data about the file' -
>> metadata. Subversion only versions directory trees, not the metadata
>> which may be associated with directory trees.

> I find it hard to draw a line between the file data and its metadata.
> Is the file name a metadatum? Are the file permissions metadata? Is it
> possible to make these distinctions regardless of the type of file system?

Subversion isn't the first program that knows how to move files around.
  This problem was solved long ago in tar, and similarly in rsync (and
both have odd extensions for mac resource forks...). There's a certain
amount of stuff to store and a certain amount that gets lost crossing
platforms. File modified timestamp is used everywhere.

> Yes, I thought about that too. That way, the file modification time
> would not be really lost but just stored in a different way.

svn info will give you the commit time of the file - and I think you are
allowed to modify this.

> I think I could also temporarily set the system time to the file
> modification time before I commit each file, just during the migration
> process. That way, commit time would always be equal to file
> modification time. But I really hope I can avoid having to do something
> a dirty as this.

Setting it to the time that svn info shows as the last changed date
might make more sense. That will at least serialize things around
commits which is probably what you want even if someone commits a file
with an old timestamp.

-- 
   Les Mikesell
    lesmikesell@gmail.com
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Feb 27 20:00:58 2007

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.