Migrate away from setup.py and use PEP 612-style pyproject.toml

Closes #240.
This commit is contained in:
Louis-Philippe Véronneau 2022-11-27 16:11:22 -05:00
parent 30d5ca1f02
commit 5fbdccc89f
No known key found for this signature in database
GPG key ID: F4257A50B21CFA85
3 changed files with 39 additions and 42 deletions

39
pyproject.toml Normal file
View file

@ -0,0 +1,39 @@
[build-system]
requires = ["setuptools"]
build-backend = "setuptools.build_meta"
[tool.setuptools]
py-modules = ['mpv']
[project]
name = "python-mpv"
version = "1.0.1"
description = "A python interface to the mpv media player"
readme = "README.rst"
authors = [{name = "jaseg", email = "github@jaseg.net"}]
license = {text = "GPLv3+"}
requires-python = ">=3.7"
keywords = ['mpv', 'library', 'video', 'audio', 'player', 'display', 'multimedia']
classifiers = [
'Development Status :: 5 - Production/Stable',
'Environment :: X11 Applications',
'Intended Audience :: Developers',
'License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)',
'License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)',
'Natural Language :: English',
'Operating System :: POSIX',
'Programming Language :: C',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Topic :: Multimedia :: Sound/Audio :: Players',
'Topic :: Multimedia :: Video :: Display'
]
[project.urls]
homepage = "https://github.com/jaseg/python-mpv"
[project.optional-dependencies]
screenshot_raw = ["Pillow"]
test = ['xvfbwrapper']

View file

@ -1,2 +0,0 @@
[metadata]
description_file = README.rst

View file

@ -1,40 +0,0 @@
#!/usr/bin/env python3
from setuptools import setup
from pathlib import Path
setup(
name = 'python-mpv',
version = '1.0.1',
py_modules = ['mpv'],
description = 'A python interface to the mpv media player',
long_description = (Path(__file__).parent / 'README.rst').read_text(),
long_description_content_type = 'text/x-rst',
url = 'https://github.com/jaseg/python-mpv',
author = 'jaseg',
author_email = 'github@jaseg.net',
license = 'GPLv2+',
extras_require = {
'screenshot_raw': ['Pillow']
},
tests_require = ['xvfbwrapper'],
test_suite = 'tests',
keywords = ['mpv', 'library', 'video', 'audio', 'player', 'display',
'multimedia'],
python_requires='>=3.7',
classifiers = [
'Development Status :: 5 - Production/Stable',
'Environment :: X11 Applications',
'Intended Audience :: Developers',
'License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)',
'License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)',
'Natural Language :: English',
'Operating System :: POSIX',
'Programming Language :: C',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Topic :: Multimedia :: Sound/Audio :: Players',
'Topic :: Multimedia :: Video :: Display']
)