Running Unix commands directly in launchd--guidelines, tips?
scp /Volumes/data/basketball/girls/data/*.txt loginid@pubsys.example.com:remote/cgi-bin/basketball/girls/data/
No problem in cron, but launchd stumbles on these kinds of things frequently. I understand that you can't necessarily have commands in there like that, but I've gotten some to run. I've discovered that rewriting some command like this to have quotes around each parameter works:
scp "/Volumes/data/basketball/girls/data/*.txt" "loginid@pubsys.example.com:remote/cgi-bin/basketball/girls/data/"
In this particular case, FWIW, that doesn't work. It still errors out, but it has worked for other commands. I'm still tinkering with it, but I'm wondering what the rules are when it comes to running commands directly in launchd like that. Are you supposed to do it this way? I'm hoping I don't have to create a separate shell script for each of these. It was really convenient in cron to be able to run commands directly in the utility itself.
Mac OS X (10.5.6)