Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.4: Back up files in the background using launchd' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Back up files in the background using launchd
Authored by: SeanAhern on Apr 13, '06 09:09:03AM

There's something funny going on in the first script, autobackup. You have a comment that begins "#Find all items in BACKUP_FOLDER"... But there's no code after that line. It would appear that your code got concatenated to the comment line. The code presumably begins with "perl scriptfind..." Thus, the code becomes:

perl scriptfind "$BACKUP_FOLDER" -regex "$BACKUP_FOLDER/[^/]*" -print0 | xargs -+0 -n 1 -J/// $HOME/bin/autobackupitem.pl /// $DEST_FOLDER 2>/dev/null

But this is still weird. No such "scriptfind" file exists in the system, and you didn't include it in the comment. Any suggestions here? Should this just be something like:

find $BACKUP_FOLDER -depth -print0 | xargs -0 -n1 -J/// $HOME/bin/autobackupitem.pl

[ Reply to This | # ]
10.4: Back up files in the background using launchd
Authored by: SeanAhern on Apr 13, '06 09:32:46AM

I think I found the answer (which should have been obvious to me, in retrospect). The line break should be here: "perl script<>find".



[ Reply to This | # ]