Hello Stackoverflowers,
I have been trying to create a single executable file out of a folder which contains a python script and some other modules and files (note: I am also using Tkinter if that is important).
I have already looked at a lot of questions/answers relating to this and tried them but none of them seem to work for me.
Here is what my folder looks like:
python-calendar #base-folder
|
|___apliclient #module
|___httplib2 #module
|___oauth2client #module
|___uritemplate #module
|___client_secrets.json #used by program.py
|___program.py #my main script
|___program.dat #updated by program.py
My question is:
How can I create a single executable file that groups all these files/folders together into a single, standalone executable file that can be run?
This is what my setup.py
file looks like for the py2exe
installer at the moment however when I run my executable, nothing happens (both from the folder and from command-line).
from distutils.core import setup
import py2exe, sys, os
sys.argv.append('py2exe')
setup(
options = {'py2exe': {'bundle_files': 1, 'compressed': True, "includes" : ['apiclient','httplib2','oauth2client',
'uritemplate'] }},
console = ["program.py"],
zipfile = None,
data_files=['client_secrets.json']
)
Any guidance on how to use py2exe
for this or any other executable creator would be really helpful. Thank you in advance.