20:00 +0200 1/7/02, Christian Jost escribe:
>>16:01 +0200 19/6/02, Christian Jost escribe:
>>>If I remember correctly you first have to activate cron before you 
>>>can use the at command. I don't remember the details, but you can 
>>>find all the necessary information in 4 articles by David Pogue 
>>>(the relevant piece is in the second one), see
>>>http://www.macdevcenter.com/pub/ct/51
>>
>>      Thanks CJ, I finally find the way of making CronniX for example 
>>to work.  You must write
>>
>>  % sudo echo "yourShortName" > /var/cron/allow
>>
>>then you'll have permission to execute cronned tasks.
>>
>>
>>The problem holds with the format of "at"  it always aswer me
>>
>>      at: incomplete time
>>
>>      at: garbled time
>>
>>with commands like
>>
>>      at now + 2 minutes "open -a Alpha"
>>
>>
>>WHY??
>
>maybe the order of arguments, check the man page. I usually put my 
>commands in a file foo.run, then I invoke it by
>at -f foo.run now + 1 minute
>and that works perfectly well.

        Thanks CJ, I did try this parameters order time ago (the syntax 
change from book to book :( and, yes, the command seems to understand 
the that syntax, then

                at -f athacer now + 1 minute

for example, does work, apparently.

I put (% cat athacer)

        #!/bin/sh
        open -a Alpha
        mkdir ~/Desktop/atFuncionando


to see clearly that the script have worked, but nothing.

I have

        /var/at 153# l
        total 16
        -rw-------  1 root  wheel    0 Jul  2 10:37 .lockfile
        -rw-r--r--  1 root  wheel    8 Jun 13 19:03 at.allow
        -rw-r--r--  1 root  wheel    1 Jul  2 10:37 at.deny
        drwxr-xr-x  5 root  wheel  126 Jul  2 10:42 jobs


with at.allow with only my logname, and at.deny empty (as is usual 
although this very last file is not necessary and I tried with and 
without it).  jobs/ contains a file for each time I issue a correct 
"at" command, like:

        /var/at 155# l jobs/
        total 24
        -rwx------  1 me  wheel  1505 Jul  2 10:37 a0104d2c6.000
        -rwx------  1 me  wheel  1535 Jul  2 10:40 a0104d2c9.000
        -rwx------  1 me  wheel  1545 Jul  2 10:42 a0104d2cb.000

but any of that files never worked.

Now, I have tried to exec one of them, they have a lot of lines like
#! /bin/sh
# mail   me 0
umask 22
HOME=\/Users\/me; export HOME
SHELL=\/bin\/tcsh; export SHELL
USER=me; export USER
etcetera
....
ending with the commands in the file -f ...

and give this error!!:

        /<1>at/jobs 161# a0104d2c6.000
        a0104d2c6.000: read-only variable: PWD [18]

        11:14:39 /<1>at/jobs 162#

in fact, there is one line in the a0104d2c6.000 file that says:

        PWD=\/Users\/me\/tmp\/tmp; export PWD

trying to assign a value to PWD.  Then I have just try

        ~ 151% sh
        me% PWD=HOLATIO
        zsh: read-only variable: PWD
        me%

the problem seems to be there, sh does not admit this.  But WHY zsh.  Look!

        11:21:01 ~ 152% l /bin/zsh
        -rwxr-xr-x  1 root  wheel  449616 Dec 31  2001 /bin/zsh
        11:21:08 ~ 153% l /bin/sh
        -r-xr-xr-x  1 root  wheel  449616 Dec 31  2001 /bin/sh

THE SAME SIZE BOTH!

The question
-- 
  juan


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Fink-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-users

Reply via email to