Ubuntu Linux and PyPE help

Ok, before anyone gets mad at me asking these basic questions let me say I have just spent over a hour trawling through the forums looking for this topic so if I missed it my bad but please help!

I am running PyPE on Ubuntu Linux and I cant figure out how to run scripts. when I was using Python for text based programs I used IDLE but that gets dodgy with panda and PyPE is better featured.

could someone please tell me how I run a script using PyPE or if I have to use the console the commands I need to write. I am new to Linux and Python, when I was using windows I programmed in Blitz3D but eventually got sick of Directx7 so I made the big switch. Help is very much appreciated as i have finally gotten my head around Panda and Python’s way of thinking and now just need practice.

As a last note, how do you compile your script into an .exe (or the equivalent for Linux/mac).

Thank you for your help, Rorkimaru

About your first question, you should go to the command line and type this:

python2.5 yourfilename.py

where yourfilename.py is the name of the python file you’ve saved in PyPE.

About compiling to .exe – on windows you can do it with py2exe or pyinstaller or an equivalent program. You can also do it with panda3d’s tool packpanda but this one will not hide your source code.

I’m not aware of equivalent tools for linux – but you could of course strip the extension off your python file, put “#!/usr/bin/env python” at the first line of your script, put it in the /usr/bin/ dir and just make everybody think its an executable and hope nobody ever opens it. But maybe there is also a py2exe around for linux-- but I’m not aware of any.

Thank you so much :smiley: you are a life saver. I was going insane trying to get this to work.

regards, rorkimaru