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

Re: Re: can I insert older versions of files? i.e. "here's backups of 3 months ago - put 'em in right revision order..."

From: FRuG FoREST <frugforest_at_gmail.com>
Date: 2004-07-17 23:02:18 CEST

Per: Submission of older files into the REPOS, retain older date

On Sat, 17 Jul 2004 08:45:50 -0500, Ben Collins-Sussman
<sussman@collab.net> wrote:
> On Fri, 2004-07-16 at 22:30, Alan Jay Weiner wrote:
>
> > Maybe it's not worth it, but if it's possible to do, I'd really like to.
>
> It's not possible to do what you want. The only thing you can do is
> what the rest of us have done:

Actually, I just posed a similar question last week. I'll summarize
what I have figured out so far....

BACKGROUND NOTES:

1) After importing the files into the REPOS, they'll have the 'current
date/time' as the file date.

2) When you 'export/checkout' the files, they'll have have "today's"
date/time.

3) You can retain original date/times, by turning on the
'~/.subversion/config' option 'use-commit-times=yes'.

4) You can turn on 'use-commit-times' globally for the whole system.
     (on the system that you are checking out files, /etc/subversion/config)

SOLUTIONS:

Here's two solutions . . . based on feedback from the 'Subversion
Users' list and some of my own ideas:

1) Use the 'svn:date' property to set the file date. [1]
     (I'm currently experimenting with a script to restore the dates
after import)

2) Dump the entire REPOS, then 'by a script' modify the commit times
in that file for each
   file based on original files-date/times. Then re-import into a new REPOS.

Neither one is 'elegant' nor clean.

FEATURE REQUEST:

Ability to 1) Import or 2) Check-in , with SVN and retain the file
dates, per option '--retain-file-dates' (or something like that). :)

Thanks,
-FRuG

Notes:
[1] Original message:
------------------------------------------------------------------------------------------------
Ben Collins-Sussman <sussman@collab.net> Fri, 09 Jul 2004 19:50:43 -0500

Here's a possible trick:

Organize your files into buckets, categorized by original dates. Then
commit each "bucket" of files in chronological order. This results in a
bunch of revisions in the repository. Then you can tweak each
revision's 'svn:date' property, so it *appears* that each bucket of
files was committed on a certain date.

In other words, because a revision's svn:date property is tweakable, you
can make the "commit times" of the files match the original times.
------------------------------------------------------------------------------------------------

[2]

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Sat Jul 17 23:02:39 2004

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