我的视图目录遇到了一个问题,它包含许多子目录和非python文件(.html, .css, .ts, .js
)。这是给你的图表
- my_python_web_app
- __init__.py
- python_app
- __init__.py
- a.py
- few.py
- python.py
- modules.py
- view
- index.html
- main.css
- script.js
- web_app
- main_app.ts
- components
- component1
- component1.html
- component1.css
- component1.ts
- component2
- component2.html
- component2.css
- component2.ts
这些文件需要保持其目录结构,以便正确地提供服务。我研究过使用MANIFEST.in并将文档作为数据文件包含在内,但这两种方法似乎都不是真正的解决方案
我最好的办法是在创建分发包之前先压缩目录,然后在pip install
期间解压缩它。。。不知怎么的。有更好的主意吗
我有一个类似结构的web应用程序。您可以在Github上找到代码
以下MANIFEST.IN和setup.py对我有效:
清单。在中:
recursive-include omxremote/static *
设置.py:
我使用
...
来标记实际setup.py包含了更多的内容,但这在这里应该不相关相关问题 更多 >
编程相关推荐