Import an old project (dated row of folders) into Subversion

Does anyone know of a simple way to import an outdated project whose "version control system" is a series of dated folders in SVN to keep track of changes?

The project that I inherited was not version controlled, and there are hundreds of folders, each of which is dated as: 2006-11-26, 2006-11-27, etc. Fortunately, it looks like they did a pretty good job of diligently creating folders, even if (within a few weeks) nothing has changed.

I would really like the script / tool, which will create a new repository with the oldest folder, and then sequentially and automatically apply all subversion commands to convert each later folder to a new version.

Hope this makes sense. The old script script is tempting me to try to solve it myself, but a) I'm sure it works more than I originally imagined, b) it is not the best use of my time (I am not an expert in writing shell scripts), and c) I fight about mortgage, someone has already done it.

Extra credit: let the script / tool also change the timestamp properties based on the folder names so that the story in the subversion is closer to reality.

I hope everything makes sense.

Thanks so much for any help.

PS I would rather do it all under Linux, but if there is a solution (gasp!) To Windows, beggars cannot be choices, can they?

+3
source share
2 answers

I think the script shell solution will not be too tough. Something like that:

for d in 200*
do
    cp -a $d/* svndir/
    cd svndir
    svn add *
    svn commit
    cd ..
done

, , , - ( , , svndir). svn commit, , .

cp -a , , , svn , . , "date" ( $d) . .

+3

load-dirs.pl, Subversion . subversion ( )

+2

Source: https://habr.com/ru/post/1698421/


All Articles