Skip to content

Commit cf58852

Browse files
committed
Switch from setup.py to pyproject.toml
The former is deprecated. Also fixes issues rendering README on PyPI.
1 parent f013b69 commit cf58852

File tree

4 files changed

+51
-41
lines changed

4 files changed

+51
-41
lines changed

.github/workflows/tests.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ jobs:
2727
cache: pip
2828
cache-dependency-path: |
2929
pyproject.toml
30-
setup.py
3130
- name: Install test dependency
3231
run: pip install tox
3332
- name: Run tests

docs/changelog.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
Changelog
22
---------
33

4+
v0.16.1
5+
~~~~~~~
6+
* Switch from ``setup.py`` to ``pyproject.toml``. Only affects how installation
7+
from source is performed, and has no runtime impact.
8+
49
v0.16.0
510
~~~~~~~
611

pyproject.toml

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,50 @@
11
[build-system]
2-
requires = ["setuptools>=45", "wheel", "setuptools_scm>=6.2"]
2+
requires = ["setuptools>=61", "wheel", "setuptools_scm>=6.2"]
3+
build-backend = "setuptools.build_meta"
4+
5+
[project]
6+
name = "python-barcode"
7+
description = "Create standard barcodes with Python. No external modules needed. (optional Pillow support included)."
8+
readme = "README.rst"
9+
requires-python = ">=3.9"
10+
license = { text = "MIT" }
11+
authors = [
12+
{ name = "Hugo Osvaldo Barrera et al", email = "[email protected]" }
13+
]
14+
classifiers = [
15+
"Development Status :: 5 - Production/Stable",
16+
"Environment :: Console",
17+
"Intended Audience :: Developers",
18+
"License :: OSI Approved :: MIT License",
19+
"Operating System :: OS Independent",
20+
"Programming Language :: Python",
21+
"Programming Language :: Python :: 3",
22+
"Programming Language :: Python :: 3.9",
23+
"Programming Language :: Python :: 3.10",
24+
"Programming Language :: Python :: 3.11",
25+
"Programming Language :: Python :: 3.12",
26+
"Topic :: Multimedia :: Graphics",
27+
"Topic :: Software Development :: Libraries :: Python Modules",
28+
]
29+
dynamic = ["version"]
30+
31+
[project.optional-dependencies]
32+
images = ["pillow"]
33+
34+
[project.scripts]
35+
python-barcode = "barcode.pybarcode:main"
36+
37+
[project.urls]
38+
documentation = "https://python-barcode.readthedocs.io/"
39+
repository = "https://github.com/WhyNotHugo/python-barcode"
40+
issues = "https://github.com/WhyNotHugo/python-barcode/issues"
41+
funding= "https://whynothugo.nl/sponsor/"
42+
43+
[tool.setuptools]
44+
include-package-data = true
45+
46+
[tool.setuptools.packages.find]
47+
exclude = ["tests"]
348

449
[tool.setuptools_scm]
550
write_to = "barcode/version.py"

setup.py

Lines changed: 0 additions & 39 deletions
This file was deleted.

0 commit comments

Comments
 (0)