Reputation: 147
Suppose I have a Windows machine A, the python package x is installed and used in script.py as:
#this is in script.py
import x
x.useit()
Then I can execute script.py in machine A like:
python script.py
Now if I copy script.py to a Mac machine B, is there a way to run script.py without install the package x there?
Upvotes: 0
Views: 44
Reputation:
the only way i think it works is using some modules like py2exe, py2app ... when u importing modules u are calling some functions and classes... so u need them for running them in program. maybe there is hard way that u can copy the module in your program(the lines u need at least..!) but i think its little dumb! and i didn't try before!
so hopefully py2app is ready to use and i think py2app will work for sure !
Upvotes: 1