开发者

Can't figure out how to include *.html files within a site-packages folder

I cannot figure out how to write my setup.py script in order to include *.html files within the i开发者_Go百科nstalled package.

Here is my attempt:

import os
from setuptools import setup, find_packages

setup(name='django-testapp',
  version='0.1',
  author='RadiantHex',
  license='BSD',
  keywords='testapp,django',
  packages=['testapp']],
  include_package_data=True,
  data_files = os.walk('testapp'),
  zip_safe = False,
  )

The *.html files are contained within the testapp folder.


Any ideas?


Add following 'package_data' argument to the setup():

setup(...,
    package_data={
        'testapp' : ['testapp/*.html']
    }, ...)
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜