From within a perl script, I need to traverse a directory and all of its contents and add DOS style newlines within all *.html files.
All I need is a function which takes the path to a directory, then traverses the whole directory and its subdirectories, replacing the newlines in all .html files with DOS style newlines. If the DOS style newlines are already there, they should be left alone.
I was using a system call to "find" and unix2dos to do this trick, except we found that unix2dos mangles our foreign language characters.
So the best solution would be to do this within Perl. I can do it myself but have no desire to go dig out my Perl books and relearn file globbing and all that. This should be trivial for an experienced perl programmer.
1) Complete and fully-functional working function as described above.
2) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).
Sun OS, Perl 5. Should be platform independent.