Skip to content

Commit

Permalink
Cleaned up setup.py
Browse files Browse the repository at this point in the history
Removed distutils support. It wasn't working anyway (Closes #25).
Removed redundant package_dir and package_data options.
Removed old testing dependencies.
Removed unnecessary wheel dependency (Closes #143).
  • Loading branch information
AWhetter committed Aug 6, 2018
1 parent a1825cd commit 763da71
Showing 1 changed file with 12 additions and 39 deletions.
51 changes: 12 additions & 39 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,34 +1,7 @@
import codecs
try:
from setuptools import setup, find_packages
extra_setup = dict(
install_requires=[
'astroid;python_version>="3"',
'astroid<2;python_version<"3"',
'PyYAML',
'wheel==0.24.0',
'sphinx',
'sphinxcontrib-golangdomain',
'sphinxcontrib-dotnetdomain',
'unidecode',
],
test_suite='nose.collector',
tests_require=['nose', 'mock'],
)
except ImportError:
from distutils.core import setup
extra_setup = dict(
requires=[
'astroid;python_version>="3"',
'astroid<2;python_version<"3"',
'PyYAML',
'wheel==0.24.0',
'sphinx'
'sphinxcontrib-golangdomain',
'sphinxcontrib-dotnetdomain',
'unidecode',
],
)

from setuptools import setup, find_packages


setup(
name='sphinx-autoapi',
Expand All @@ -38,16 +11,16 @@
url='http://github.com/rtfd/sphinx-autoapi',
license='BSD',
description='Sphinx auto API documentation generator',
package_dir={'': '.'},
packages=find_packages('.'),
long_description=codecs.open("README.rst", "r", "utf-8").read(),
# trying to add files...
include_package_data=True,
package_data={
'autoapi': [
'templates/*.rst',
'templates/*/*.rst',
],
},
**extra_setup
install_requires=[
'astroid;python_version>="3"',
'astroid<2;python_version<"3"',
'PyYAML',
'sphinx',
'sphinxcontrib-golangdomain',
'sphinxcontrib-dotnetdomain',
'unidecode',
],
)

0 comments on commit 763da71

Please sign in to comment.