Subject: | |
From: | |
Reply To: | |
Date: | Mon, 24 Jul 2006 12:16:10 -0700 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
On Jul 24, 2006, at 10:33 AM, Duane Mitchell wrote:
>
> I've got a script that contains a short "do shell perl ..." line in
> it. I run the line from the Terminal and it works. I save the
> script as an application and double-click it and it works. I have
> crontab launch the script application and I get an error message:
> "sh: line 1: perl: command not found"
>
> I checked the env info for the current logged in user and the path
> to perl is included. I'm stumped...suggestions anybody...thanks.
cron runs crontab things with a very limited environment. It is
likely that perl isn't in any of the (few or none) directories in
that environment's PATH variable.
The command
which perl
executed in terminal shows that Apple--as is common--has perl in
/usr/bin/perl
It sounds as if you have the short perl script in your command line
using -e 'blah'...if so use /usr/bin/perl in place of perl. If you
have an actual perl source file, use
#!/usr/bin/perl
rather than
#!perl
as its first line.
"They" do this to help us.
--John
|
|
|