diff --git a/MANIFEST.in b/MANIFEST.in index 21c64aee7f..f12c8bb4e7 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -2,6 +2,7 @@ # one-liner to get extensions in package: set([l.split(",")[0].split('.')[-1] for l in open('files.txt').readlines()]) recursive-exclude arcade *.pyc +recursive-include arcade *.typed recursive-include arcade/resources *.txt *.md *.url recursive-include arcade/resources *.mp3 *.wav *.ogg recursive-include arcade/resources *.png *.jpg *.gif diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000000..07de284aa5 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,3 @@ +[build-system] +requires = ["setuptools", "wheel"] +build-backend = "setuptools.build_meta" \ No newline at end of file diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index a96c74a2b0..0000000000 --- a/requirements.txt +++ /dev/null @@ -1,18 +0,0 @@ -numpy -Pillow -Pyglet>=1.5.4,<2 -pytiled-parser==0.9.4a3 -pytest -pymunk -matplotlib -wheel -twine -sphinx-sitemap -sphinx_rtd_theme -sphinx-copybutton -flake8 -zstandard -mypy -coverage -tox -pyyaml diff --git a/requirements_dev.txt b/requirements_dev.txt deleted file mode 100644 index a2b33b21d0..0000000000 --- a/requirements_dev.txt +++ /dev/null @@ -1,9 +0,0 @@ --e . -coverage -coveralls -mypy -flake8 -pytest -pytest-cov -pytest-mock -setuptools diff --git a/setup.cfg b/setup.cfg index bb9fe91600..845f051592 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,3 +1,68 @@ +[metadata] +name = arcade +description = Arcade Game Development Library +long_description = file: README.rst +author = Paul Vincent Craven +author_email = paul.craven@simpson.edu +license = MIT +license-file = license.rst +url = https://arcade.academy +download_url = https://arcade.academy +project_urls = + Documentation = https://arcade.academy/ + Example Code = http://arcade.academy/examples/index.html + Issue Tracker = https://github.com/pvcraven/arcade/issues + Source = https://github.com/pvcraven/arcade + On-line Book = http://learn.arcade.academy/ +classifiers = + Development Status :: 5 - Production/Stable + Intended Audience :: Developers + License :: OSI Approved :: MIT License + Operating System :: OS Independent + Programming Language :: Python + Programming Language :: Python :: 3.6 + Programming Language :: Python :: 3.7 + Programming Language :: Python :: 3.8 + Programming Language :: Python :: Implementation :: CPython + Topic :: Software Development :: Libraries :: Python Modules + +[options] +packages = find: +include_package_data = True +python_requires = >=3.6 +install_requires = + pyglet>=1.5.8,<2 + pillow ~= 8.0 + numpy ~= 1.19 + pymunk ~= 5.7 + pyyaml ~= 5.3 + pytiled-parser == 0.9.4a3 + dataclasses;python_version<'3.7' + +[options.packages.find] +include = + arcade + arcade.* + +[options.extras_require] +dev = + pytest + flake8 + mypy + coverage + coveralls + pytest-mock + pytest-cov + +build = + pep517 + +docs = + sphinx + sphinx-sitemap + sphinx_rtd_theme + sphinx-copybutton + [build_sphinx] source-dir = doc build-dir = doc/build diff --git a/setup.py b/setup.py index b50f297a3a..eb23ca4326 100644 --- a/setup.py +++ b/setup.py @@ -1,85 +1,5 @@ #!/usr/bin/env python +from setuptools import setup -from os import path -import sys -from setuptools import setup, find_namespace_packages - -VERSION = 'default' -def execfile(filepath, globals=None, locals=None): - if globals is None: - globals = {} - globals.update({ - "__file__": filepath, - "__name__": "__main__", - }) - with open(filepath, 'rb') as file: - exec(compile(file.read(), filepath, 'exec'), globals, locals) - - -# execute the file -execfile("arcade/version.py", locals=locals()) - -RELEASE = VERSION - -if __name__ == "__main__": - - install_requires = [ - 'pyglet', - 'pillow', - 'numpy', - 'pytiled-parser==0.9.4a3', - 'pymunk', - 'pyyaml' - ] - if sys.version_info[0] == 3 and sys.version_info[1] == 6: - install_requires.append('dataclasses') - - if "--format=msi" in sys.argv or "bdist_msi" in sys.argv: - # hack the version name to a format msi doesn't have trouble with - VERSION = VERSION.replace("-alpha", "a") - VERSION = VERSION.replace("-beta", "b") - VERSION = VERSION.replace("-rc", "r") - - fname = path.join(path.dirname(path.abspath(__file__)), "README.rst") - with open(fname, "r") as f: - long_desc = f.read() - - setup( - name="arcade", - version=RELEASE, - description="Arcade Game Development Library", - long_description=long_desc, - author="Paul Vincent Craven", - author_email="paul.craven@simpson.edu", - license="MIT", - url="http://arcade.academy", - download_url="http://arcade.academy", - install_requires=install_requires, - packages=find_namespace_packages( - include=["arcade", "arcade.*"], - exclude=[], - ), - python_requires='>=3.6', - classifiers=[ - "Development Status :: 5 - Production/Stable", - "Intended Audience :: Developers", - "License :: OSI Approved :: MIT License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3.6", - "Programming Language :: Python :: 3.7", - "Programming Language :: Python :: 3.8", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries :: Python Modules", - ], - # include_package_data: If set to True, this tells setuptools to automatically include - # any data files it finds inside your package directories that are specified by your MANIFEST.in file. - include_package_data=True, - project_urls={ - 'Documentation': 'https://arcade.academy/', - 'Example Code ': 'http://arcade.academy/examples/index.html', - 'Issue Tracker': 'https://github.com/pvcraven/arcade/issues', - 'Source': 'https://github.com/pvcraven/arcade', - 'On-line Book': 'http://learn.arcade.academy/', - }, -) +exec(open("arcade/version.py").read()) +setup(version=VERSION)