diff --git a/MANIFEST.in b/MANIFEST.in index deea683c..88714452 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -2,4 +2,8 @@ include LICENSE include README.rst recursive-include silk/templates * recursive-include silk/static * +recursive-include silk/code_generation/ *.py +recursive-include silk/profiling/ *.py +recursive-include silk/utils/ *.py +recursive-include silk/views/ *.py recursive-include silk *.py diff --git a/package.py b/package.py deleted file mode 100644 index 44dcb453..00000000 --- a/package.py +++ /dev/null @@ -1,52 +0,0 @@ -""" -Package up silky for a release. -""" -import os -import shutil -import sys - -import jinja2 -import subprocess - - -SCRIPT_DIR = os.path.dirname(os.path.realpath(__file__)) -DIST_DIR = SCRIPT_DIR + '/dist/{version}' - - - -def main(): - try: - version = sys.argv[1] - dist_dir = DIST_DIR.format(version=version) - if not os.path.exists(dist_dir): - os.makedirs(dist_dir) - with open(SCRIPT_DIR + '/setup.py.jinja2') as f: - template = jinja2.Template(f.read()) - with open(dist_dir + '/setup.py', 'w') as f: - f.write(template.render(version=version)) - readme_file_name = '/README.rst' - license_file_name = '/LICENSE' - manifest_file_name = '/MANIFEST.in' - for file_name in readme_file_name, license_file_name, manifest_file_name: - shutil.copyfile(SCRIPT_DIR + file_name, dist_dir + file_name) - silk_dir = dist_dir + '/silk/' - if os.path.exists(silk_dir): - shutil.rmtree(silk_dir) - shutil.copytree(SCRIPT_DIR + '/django_silky/silk/', silk_dir) - template_dir = silk_dir + 'templates/silk/' - shutil.copytree(template_dir, template_dir + 'templates/silk') - cmd = 'cd %s && python setup.py sdist' % dist_dir - print(cmd) - subprocess.call(cmd, shell=True) - archive_name = 'django-silk-%s.tar.gz' % version - from_file = dist_dir + ('/dist/' + archive_name) - to_file = dist_dir + '/../' + archive_name - print('Copying from %s to %s' % (from_file, to_file)) - shutil.copy2(from_file, to_file) - #shutil.rmtree(dist_dir) - except IndexError: - print('Usage: %s ' % sys.argv[0]) - - -if __name__ == '__main__': - main() diff --git a/setup.py.jinja2 b/setup.py.jinja2 deleted file mode 100644 index a2a28716..00000000 --- a/setup.py.jinja2 +++ /dev/null @@ -1,44 +0,0 @@ -import os -from setuptools import setup - -with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme_file: - README = readme_file.read() - -# allow setup.py to be run from any path -os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) - -setup( - name='django-silk', - version='{{ version }}', - packages=['silk'], - include_package_data=True, - license='MIT License', - description='A Django app for profiling other Django apps', - long_description=README, - url='http://www.mtford.co.uk/projects/silk/', - author='Michael Ford', - author_email='mtford@gmail.com', - classifiers=[ - 'Environment :: Web Environment', - 'Framework :: Django', - 'Intended Audience :: Developers', - 'Operating System :: OS Independent', - 'Programming Language :: Python', - 'Programming Language :: Python :: 2.7', - 'Programming Language :: Python :: 3.3', - 'Programming Language :: Python :: 3.4', - 'Topic :: Internet :: WWW/HTTP', - 'Topic :: Internet :: WWW/HTTP :: Dynamic Content', - ], - install_requires= [ - 'Django>=1.4,<=1.6', - 'Pygments==1.6', - 'six==1.6', - 'simplejson>=3,<4', - 'python-dateutil>=2,<3', - 'requests>=2,<=3', - 'sqlparse>=0.1,<0.2', - 'Jinja2>=2.7,<3', - 'autopep8>=1,<2' - ] -)