Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to make others use my Python Script [duplicate]

I am just finished with my script in Python and i want my collegues to use it as well. It runs in python 2.7 Windows 7 64 bit professional env. Now comes the question:

How can i make them use my script in an easy way?

  • First choice is the hard way, making them install python on their machines and then install paramiko,Tkinter . I had a very hard time finding & installing these modules (especially for windows binary files) and do not want to suffer from the same issues again.

  • I am a newbie in this environment and I think there would be practical solutions to this problem. So i wanted to ask you guys , any ideas appreciated.

like image 737
Krcn U Avatar asked Jun 24 '13 13:06

Krcn U


People also ask

Can you run the same Python script twice?

You can run multiple instances of a python script from a shell however from within a python program without the use of multithreading/multiprocessing the GIL limitation will impact what you are trying to do.

How do you make a program copy itself in Python?

Copying the script can be done with shutil. copy() . But you should consider keeping your script under revision control.


2 Answers

You can use py2exe(windows), py2app(Mac OS X) or cx_freeze to convert your application to an executable.

cx_Freeze is cross platform and should work on any platform that Python itself works on.

like image 85
Ashwini Chaudhary Avatar answered Sep 18 '22 20:09

Ashwini Chaudhary


You need to convert it to an executable. py2exe is a module that does this for you.

Follow the tutorial here.

like image 26
Inbar Rose Avatar answered Sep 20 '22 20:09

Inbar Rose