From 6ba83038465e7d087e9abd191007c55d331129ff Mon Sep 17 00:00:00 2001 From: mulhern Date: Tue, 29 Sep 2026 12:45:46 -0400 Subject: [PATCH] Use exclusively pyproject.toml for project metadata Signed-off-by: mulhern --- pyproject.toml | 36 +++++++++++++++++++++++++++++++++++- setup.cfg | 33 --------------------------------- setup.py | 25 ------------------------- 3 files changed, 35 insertions(+), 59 deletions(-) delete mode 100644 setup.cfg delete mode 100644 setup.py diff --git a/pyproject.toml b/pyproject.toml index 470ed2c..a7e0cb2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,41 @@ [build-system] -requires = ["setuptools"] +requires = ["setuptools>=77"] build-backend = "setuptools.build_meta" +[project] +name = "justbytes" +authors = [{name = "Anne Mulhern", email = "amulhern@redhat.com"}] +description = "computing with and displaying bytes" +license = "LGPL-2.1-or-later" +classifiers = [ + "Development Status :: 2 - Pre-Alpha", + "Intended Audience :: Developers", + "Operating System :: POSIX :: Linux", + "Programming Language :: Python", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: Implementation :: CPython", + "Topic :: Software Development :: Libraries", + "Topic :: System :: Hardware", + "Topic :: System :: Operating System Kernels :: Linux", +] +urls = {Homepage = "https://github.com/mulkieran/justbytes"} +requires-python = ">=3.12" +dependencies = ["justbases>=0.13"] +dynamic = ["version"] + +[project.readme] +file = "README.rst" +content-type = "text/x-rst" + +[tool.setuptools] +package-dir = {"" = "src"} +packages = ["justbytes"] +platforms = ["Linux"] +include-package-data = false + +[tool.setuptools.dynamic] +version = {attr = "justbytes.version.__version__"} + [tool.ruff] target-version = "py312" line-length = 88 diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index f934029..0000000 --- a/setup.cfg +++ /dev/null @@ -1,33 +0,0 @@ -[metadata] -name = justbytes -author = Anne Mulhern -author_email = amulhern@redhat.com -url = https://github.com/mulkieran/justbytes -description = "computing with and displaying bytes" -license = LGPL-2.1-or-later -long_description = file: README.rst -long_description_content_type = text/x-rst -version = attr: justbytes.version.__version__ -platforms = - Linux -classifiers = - Development Status :: 2 - Pre-Alpha - Intended Audience :: Developers - Operating System :: POSIX :: Linux - Programming Language :: Python - Programming Language :: Python :: 3 - Programming Language :: Python :: Implementation :: CPython - Topic :: Software Development :: Libraries - Topic :: System :: Hardware - Topic :: System :: Operating System Kernels :: Linux - -[options] -python_requires = >=3.12 -install_requires = - justbases>=0.13 - -package_dir = - =src - -packages = - justbytes diff --git a/setup.py b/setup.py deleted file mode 100644 index 82aed6a..0000000 --- a/setup.py +++ /dev/null @@ -1,25 +0,0 @@ -# -*- coding: utf-8 -*- -# Copyright (C) 2015 - 2019 Red Hat, Inc. -# -# This library is free software; you can redistribute it and/or -# modify it under the terms of the GNU Lesser General Public -# License as published by the Free Software Foundation; either -# version 2.1 of the License, or any later version. -# -# This library is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# Lesser General Public License for more details. -# -# You should have received a copy of the GNU Lesser General Public -# License along with this library; If not, see . -# -# Red Hat Author(s): Anne Mulhern - -""" -Python packaging file for setup tools. -""" - -import setuptools - -setuptools.setup()