Open gauthierbuttez opened 4 years ago
The documentation for py2app is suboptimal at best. I've inherited the project years ago without documentation and haven't had time to fix that.
Adding datafiles to the generated app bundle is done using the "resources" option (either as --resources on the command line, or in options["py2app"] through code:
setup(
...
options={
"py2app": {
"resources": ...
}
}
)
Resources is a list of items, where every item is either:
This is patterned on the "data_files" option for py2exe: http://www.py2exe.org/index.cgi/data_files
Hi,
Thank you for your work. It looks promising but I couldn't yet test it.
I am surprised you don't give any explanation about DATA_FILES !
https://prnt.sc/ug4gei
So I made a Google search about it and I just found some specific question on particular cases on Stackoverflow. I found also some tutorial about how to compile a python code in app, but nothing consistent for DATA_FILES! I also found the existence of some kind of "resource" folder option, and guess what! No tutorial, no doc, no article, no discussion, nothing. Maybe I misunderstood and this option doesn't exist.
I guess you are very busy to produce a full tutorial or documentation about your software, so I will simply present you my needs. I hope you will have time to reply to my questions.
I made a software in Python 3.8 on Mac OS X 10.15 catalina. I would like to distribute my software to Mac OS X devices.
For my personal organization of my code and future distribution, I created in my project folder a folder named 'necessary_files' where I add some files and folders necessary to run my software properly.
These are the data I need to add in my app. These files and folder below are located in the root folder of my python project where is also my main code MyApp.py:
The examples found on google are not understandable at all as sometimes I find some tuples ,sometimes some list, sometimes both... without explanation it is hard to guess what is the syntax.
Also what about resource option? Does it exist and when should I use it?
Thanks in advance to make it more clear how to use Py2app.