diff options
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -10,6 +10,7 @@ from distutils.version import LooseVersion import warnings import io +import sys if isfile("MANIFEST"): os.unlink("MANIFEST") @@ -21,29 +22,31 @@ if LooseVersion(setuptools.__version__) <= LooseVersion("24.3"): class Unsupported(TestCommand): def run(self): - print("Running 'test' with setup.py is not supported. " - "Use 'pytest' or 'tox' to run the tests.") + sys.stderr.write("Running 'test' with setup.py is not supported. " + "Use 'pytest' or 'tox' to run the tests.\n") + sys.exit(1) + ### # Load metadata PACKAGES = find_packages(where='.', exclude=['dateutil.test']) + def README(): with io.open('README.rst', encoding='utf-8') as f: readme_lines = f.readlines() # The .. doctest directive is not supported by PyPA lines_out = [] - doctest_line_found = False for line in readme_lines: if line.startswith('.. doctest'): - doctest_line_found = True lines_out.append('.. code-block:: python3\n') else: lines_out.append(line) return ''.join(lines_out) -README = README() +README = README() # NOQA + setup(name="python-dateutil", use_scm_version={ @@ -62,9 +65,8 @@ setup(name="python-dateutil", python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*", package_data={"dateutil.zoneinfo": ["dateutil-zoneinfo.tar.gz"]}, zip_safe=True, - requires=["six"], setup_requires=['setuptools_scm'], - install_requires=["six >=1.5"], # XXX fix when packaging is sane again + install_requires=["six >=1.5"], classifiers=[ 'Development Status :: 5 - Production/Stable', 'Intended Audience :: Developers', |