[Pythonmac-SIG] I don't understand

Bob Ippolito bob at redivi.com
Sat May 6 21:53:07 CEST 2006


On May 6, 2006, at 12:35 PM, Jan Erik Moström wrote:

> I was playing with appscript and created a script and everything  
> worked just
> fine when I ran it from within BBEdit. Then I moved it to its  
> proper place
> and tried to use it from the command line, didn't work, it didn't  
> understand
> the "import" command (unknown command).
>
> I started to cut down on the code and ended up with
> ---------------------------------
> #!/usr/local/bin/pythonw
>
> print 'hello world'
> ---------------------------------
>
>> ./test.py
> ./test.py: line 3: print: command not found

You need to upgrade to Universal Python, or use /usr/bin/env in your  
#! line.

-bob



More information about the Pythonmac-SIG mailing list