Hi Phil, good to know that the script works in some way like you want it to. Regarding DEBUG output thats a good idea and I implemented that first. For compatibility I would like to keep the script sh conform. Can you say what needs to be done for rewriting ignore patterns. Regarding the PREFIX_ONE / PREFIX_TWO i used this, because first approach was of moving PREFIX_ONE directory. This is now removed, as i've rewritten some parts. What I do now is to check all files/dirs in wc-path to dir-structure in FSVS_WAA. Before I do a reverse sort so that deepest path in tree is taken first. So i can keep sure that files are not moved to the wrong (parental) working copy. I also added some exclude directory handling for speed-up the search. For some things like animation :-) and a better option handling I need a little more time. Its only a draftstate for me to get sure this is right direction, and my experience is still script-kiddie ;-) . Although many thanks for honoring the work.
Rgds, Gunnar script is now in svn: svn http://thielebein.net/repo/fsvs/migration.sh http://thielebein.net/trac/browser/fsvs/migration.sh P.Marek wrote: > I took a quick look, and ran it on my system - and it seems to work fine. > > Here are two patches for the cleanup part, and renaming the URLs file - both > untested. > > What's left to do is the rewriting of the ignore patterns. > > And I'd propose changing your progress messages to have a "# " in front, > the "echo <cmd>" statements to "$DEBUG <cmd>", and setting $DEBUG to "echo" > or "", depending on some commandline parameter. > Then people can take a look what would happen, and possibly even redirect the > output into a file to be used with "bash <filename>" directly. > > Furthermore I'd suggest to change the PREFIX_ calculation to something like > this: > # Only the path below $FSVS_WAA > find $FSVS_WAA -type f -printf "%P\n" | > # Do streaming, as this could be several thousand files. > while IFS=/ read PREFIX_ONE PREFIX_TWO SUB_PATH > do > j=$FSVS_WAA/$PREFIX_ONE/$PREFIX_TWO/$SUB_PATH > > although I have to admit I don't quite understand why PREFIX_ONE etc. are > really used - you do a "mkdir -p", so the levels in the middle are created > anyway. > If you don't need them, you could replace that with > find ... | while read j > > > If it gets a "help" or "usage" parameter (which prints some text), and > possibly a "doitreally" (which sets DEBUG to "") ... that would make it > nearly perfect, only a fine ASCII-art animation could be displayed while > doing the work ;-) > > Nice work; good that you're including some documentation inline. > > > Gunnar, *thank you very much*. You'll receive (at least) a honorable mention; > maybe you'll even have a free wish (feature-wise) - and for the moment I'll > just assume that you'd like http/https authentication running, so I'll try to > get that working (although I have no real test environment). > > > Regards, > > Phil > > ------------------------------------------------------ http://fsvs.tigris.org/ds/viewMessage.do?dsForumId=3923&dsMessageId=983735 To unsubscribe from this discussion, e-mail: [[email protected]].
