exe to py code example

Example 1: how to convert a pyw to exe

#if you dont have pyinstaller so run the cmd (winkey + r and write cmd and enter)
#now run the command bellow

	pip install pyinstaller
    
#now run this

	pyinstaller -w file_name.pyw
    #if you want the exe to be in one file without other folders 
    #change the code to: pyinstaller -w --onefile file_name.pyw
    
    
#change file_name to your file's name and if you aren't running the cmd in the
#same directory so instead of the file's name write the all path
#now you will have a directory named Build and in it you will find your exe file
#note - if your pyw filw has dependents so they will be in the file so dont remove them

Example 2: python to exe

pip install pyinstaller

cd FullPathOfFile in cmd console
pyinstaller --onefile pythonScriptName.py
# a .exe file is created in the FullPathOfFile\dist

Example 3: how to convert python to exe

Install pip using
	pip install pyinstaller

in the directory of the source code file run
	pyinstaller <file_name>.py

Example 4: python to exe

pip install pyinstaller

Example 5: how to convert python file to exe

# for windows only, connot say for other operating systems
open command prompt
 type "pip install pyinstaller"
# let it install
after it is installed
 locate to the file in cmd(command prompt) using cd
  for example : cd /folder/location
after you are in that folder type:
    pyinstaller file_name.py --onefile -w
# in place of file_name.py type the file's name you want to convert.
now pyinstaller will give you different type of files 
 to locate the .exe file you want go into the folder,
  then go into dist folder and you will find it.
now you are done! BOYAAH !!
@important note -> if this gives you an error then you need to use py2exe module
# Author Rudra the great

Example 6: python to .exe online

$ auto-py-to-exe

Tags: