diff options
| author | Jannis Leidel <jannis@leidel.info> | 2019-10-18 15:57:13 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-10-18 15:57:13 +0200 |
| commit | f6bf14afd22d8e5b706670590cc95f29d4483434 (patch) | |
| tree | a65fbc8b6fd1112222beb6f66c31082ffe231460 /setup.py | |
| parent | f3d02aa3b088e2f9044fe5e4869e8c8cb91d2cdc (diff) | |
| download | tablib-f6bf14afd22d8e5b706670590cc95f29d4483434.tar.gz | |
Add project release config and cleanup project setup. (#398)
* Add project release config and use Travis build stages.
Refs #378.
* Restructure project to use src/ and tests/ directories.
* Fix testing.
* Remove eggs.
* More fixes.
- isort and flake8 config
- manifest template update
- tox ini extension
- docs build fixes
- docs content fixes
* Docs and license cleanup.
Diffstat (limited to 'setup.py')
| -rwxr-xr-x | setup.py | 37 |
1 files changed, 7 insertions, 30 deletions
@@ -5,31 +5,9 @@ import os import re import sys -from setuptools import setup +from setuptools import find_packages, setup -if sys.argv[-1] == 'publish': - os.system("python setup.py sdist upload") - sys.exit() - - -if sys.argv[-1] == 'test': - try: - __import__('py') - except ImportError: - print('py.test required.') - sys.exit(1) - - errors = os.system('py.test test_tablib.py') - sys.exit(bool(errors)) - -packages = [ - 'tablib', 'tablib.formats', - 'tablib.packages', - 'tablib.packages.dbfpy', - 'tablib.packages.dbfpy3' -] - install = [ 'odfpy', 'openpyxl>=2.4.0', @@ -41,21 +19,21 @@ install = [ ] -with open('tablib/core.py', 'r') as fd: - version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]', - fd.read(), re.MULTILINE).group(1) - setup( name='tablib', - version=version, + use_scm_version=True, + setup_requires=['setuptools_scm'], description='Format agnostic tabular data library (XLS, JSON, YAML, CSV)', long_description=(open('README.md').read() + '\n\n' + open('HISTORY.md').read()), long_description_content_type="text/markdown", author='Kenneth Reitz', author_email='me@kennethreitz.org', + maintainer='Jazzband', + maintainer_email='roadies@jazzband.co', url='https://tablib.readthedocs.io', - packages=packages, + packages=find_packages(where="src"), + package_dir={"": "src"}, license='MIT', classifiers=[ 'Development Status :: 5 - Production/Stable', @@ -71,7 +49,6 @@ setup( 'Programming Language :: Python :: 3.7', ], python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*', - tests_require=['pytest'], install_requires=install, extras_require={ 'pandas': ['pandas'], |
