|The stupid question is the question not asked|
TAR Escapingby davemcgi (Novice)
|on Jul 20, 2005 at 09:18 UTC||Need Help??|
davemcgi has asked for the
wisdom of the Perl Monks concerning the following question:
I'm doing an incremental backup system using Perl and TAR.
I spider the directories, checking and comparing mtime and size against recorded database entries, updating and adding as necessary. Then I generate a list of files to process through TAR.
I have run up against a problem with TAR itself, I know this isn't strictly a Perl question, but maybe some unix guru has some suggestions.
I will issue this system command :-
tar -c -P -T ListOfFiles.txt -f MyTarFile.tar
where ListOfFiles.txt contains the following entries, delimited by usual chr(10) :-
When TAR is running, he is adding in an escape character to the third file, then of course reporting an error as he can't find the file on the disk.
So how to avoid TAR doing this escaping ?
Thanks for any suggestions,