-1

I have made a program which uses pygame, tkinter, pyttsx3 and more. I want to convert this program to and executable .exe file to share with my friends. How can I do that without any issues?

  • 4
    Does this answer your question? [How can I convert a .py to .exe for Python?](https://stackoverflow.com/questions/41570359/how-can-i-convert-a-py-to-exe-for-python) – xszym Sep 07 '20 at 12:59
  • Does this answer your question? [Converting tkinter to exe](https://stackoverflow.com/questions/48299396/converting-tkinter-to-exe) – drops Sep 07 '20 at 12:59

2 Answers2

0

To convert your pythone code into an executable file I suggest to use the tool pyinstaller. in your command prompt:

> pip install pyinstaller

Then in cmd open the current folder where you have the code stored. For example

> D:
> cd folder

Then you just run the command (with the name of your file where you have the code):

> pyinstaller --onefile code.py

You will find your executable in a separate folder called dist

I hope it helps you, it should work. It is how I transformed my codes into executable.

Doru Bolboceanu
  • 154
  • 1
  • 7
0

An alternative is py2exe.

pip install py2exe

Or on Linux:

pip3 install py2exe

Here's the link to the tutorial on the py2exe website. https://www.py2exe.org/index.cgi/Tutorial

Lykas
  • 52
  • 8