I don't think SVN has that functionality built in, but if you are able to run commands on the server that holds the SVN repository (and assuming the server has the standard UNIX/Linux tools available), this bash script should do it for you:
REPOS=/path/to/repos
FILE=dir/foo.xml
for rev in "$(svnlook history $REPOS $FILE | awk 'NR > 2 { print $1 }')"; do
rev_date=$(svnlook date -r $rev $REPOS | awk '{ print $1 }')
svnlook cat -r $rev $REPOS $FILE > ${rev_date}_${FILE}
done
This will produce filenames of the form 2007-08-08_foo.xml
. Of course, you have to change /path/to/repos
in the first line to the actual filesystem path (not a URL) of the repository, and dir/foo.xml
in the second line to the path of the file within the repository.
If it's really important to you to have underscores in the date, change line 4 as follows:
rev_date=$(svnlook date -r $rev $REPOS | awk '{ print $1 }' | tr - _)
Also keep in mind that if the file was ever modified more than once on a given day, only the first edit on each day will actually be reflected in the written files.
While this is not a direct answer to your question, you might want to use 'svn annotate filename'. That is a good way to study evolution. – vtest – 2010-07-05T10:09:49.077