Stoopid script failure

Ed Greshko Ed.Greshko at greshko.com
Sat Feb 6 15:34:30 UTC 2010


Ed Greshko wrote:
> Patrick O'Callaghan wrote:
>   
>> Can anyone explain why this doesn't work? I've been writing shell
>> scripts on and off for several decades and I can't see what's going on
>> here. Is senility setting it?
>>
>> $ cat > tst
>> #!/bin/sh
>> echo foo
>> $ chmod +x tst
>> $ ls -l tst
>> -rwxrwxr-x 1 poc poc 19 2010-02-06 10:22 tst
>> $ type tst
>> tst is ./tst
>> $ tst
>> bash: ./tst: Permission denied
>>
>> (SElinux is off, if it matters).
>>
>>   
>>     
> I'm fairly sure you need the ./tst incantation unless you have . in your
> $PATH.  I recall somewhere, sometime a warning against that....but I've
> ignored it for years and haven't had a problem.  I even forgot what the
> warning was all about.
>
>   
I retract that last paragraph as rubbish...as I misread "permission
denied"...

-- 
Mix a little foolishness with your serious plans; it's lovely to be
silly at the right moment. -- Horace

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 253 bytes
Desc: OpenPGP digital signature
Url : http://lists.fedoraproject.org/pipermail/users/attachments/20100206/f2b96629/attachment.bin 


More information about the users mailing list