I am trying to figure out the basic structure for a python program I am writing that must include non-python resources for its functionality. In particular, it includes HTML, CSS, JS, and images that it must copy out of the package for report generation. The basic structure currently looks like this:
/project
/my-package
/sub-package-a
__init__.py
...
/sub-package-b
__init__.py
...
/static-content
stuff.html
...
__init__.py
util.py
command.py
My basic questions is this: if I, from an arbitrary directory, run python my-package/command.py
or python -m my-package
, how do I get access to the files inside of static-content
. If I later turn this into an installable egg, does this change?