Skip to content

Commit 872fe19

Browse files
committed
Switch to building with hatchling
1 parent e3f1cdd commit 872fe19

3 files changed

Lines changed: 47 additions & 41 deletions

File tree

MANIFEST.in

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

pyproject.toml

Lines changed: 47 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,75 @@
1-
[tool.ruff]
2-
target-version = "py38"
3-
line-length = 85
1+
[build-system]
2+
requires = ["hatchling"]
3+
build-backend = "hatchling.build"
4+
5+
[project]
6+
name = "pycparserext"
7+
version = "2024.1"
8+
description = "Extensions for pycparser"
9+
readme = "README.rst"
10+
license = "MIT"
11+
requires-python = "~=3.8"
12+
authors = [
13+
{ name = "Andreas Kloeckner", email = "inform@tiker.net" },
14+
]
15+
classifiers = [
16+
"Development Status :: 4 - Beta",
17+
"Intended Audience :: Developers",
18+
"Intended Audience :: Other Audience",
19+
"Intended Audience :: Science/Research",
20+
"License :: OSI Approved :: MIT License",
21+
"Natural Language :: English",
22+
"Programming Language :: Python",
23+
"Topic :: Utilities",
24+
]
25+
dependencies = [
26+
"ply>=3.4",
27+
"pycparser~=2.21",
28+
]
29+
30+
[project.urls]
31+
Homepage = "https://github.com/inducer/pycparserext"
432

33+
[tool.hatch.build.targets.sdist]
34+
include = [
35+
"/pycparserext",
36+
]
37+
[tool.ruff]
538
preview = true
39+
640
[tool.ruff.lint]
741
extend-select = [
842
"B", # flake8-bugbear
943
"C", # flake8-comprehensions
1044
"E", # pycodestyle
1145
"F", # pyflakes
46+
"G", # flake8-logging-format
1247
"I", # flake8-isort
1348
"N", # pep8-naming
1449
"NPY", # numpy
1550
"Q", # flake8-quotes
51+
"UP", # pyupgrade
52+
"RUF", # ruff
1653
"W", # pycodestyle
1754
]
1855
extend-ignore = [
1956
"C90", # McCabe complexity
2057
"E221", # multiple spaces before operator
2158
"E226", # missing whitespace around arithmetic operator
2259
"E402", # module-level import not at top of file
60+
"UP006", # updated annotations due to __future__ import
61+
"UP007", # updated annotations due to __future__ import
62+
"UP031", # use f-strings instead of %
63+
"UP032", # use f-strings instead of .format
2364
]
2465
[tool.ruff.lint.flake8-quotes]
2566
docstring-quotes = "double"
2667
inline-quotes = "double"
2768
multiline-quotes = "double"
2869

29-
[tool.ruff.lint.per-file-ignores]
30-
"pycparserext/ext_c_generator.py" = ["N802"]
31-
"test/test_pycparserext.py" = ["N802"]
70+
[tool.ruff.lint.pep8-naming]
71+
extend-ignore-names = ["visit_*", "t_*"]
72+
3273

3374
[tool.ruff.lint.isort]
3475
combine-as-imports = true
@@ -40,4 +81,3 @@ known-local-folder = [
4081
"pycparserext",
4182
]
4283
lines-after-imports = 2
43-

setup.py

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

0 commit comments

Comments
 (0)