Skip to content

Commit dc6553e

Browse files
committed
Use flit to build pip distributions
1 parent 65da0ff commit dc6553e

File tree

6 files changed

+56
-72
lines changed

6 files changed

+56
-72
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ jobs:
8282
- run: pip install nox
8383
- run: nox -s prepare-release -- 99.9
8484
- run: nox -s build-release -- 99.9
85-
- run: pipx run check-manifest
85+
- run: pipx run check-sdist
8686

8787
vendoring:
8888
name: vendoring

MANIFEST.in

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

build-project/build-requirements.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
build
2-
setuptools
2+
flit-core

build-project/build-requirements.txt

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,15 @@ build==1.2.2.post1 \
88
--hash=sha256:1d61c0887fa860c01971625baae8bdd338e517b836a2f70dd1f7aa3a6b2fc5b5 \
99
--hash=sha256:b36993e92ca9375a219c99e606a122ff365a760a2d4bba0caa09bd5278b608b7
1010
# via -r build-requirements.in
11-
packaging==24.2 \
12-
--hash=sha256:09abb1bccd265c01f4a3aa3f7a7db064b36514d2cba19a2f694fe6150451a759 \
13-
--hash=sha256:c228a6dc5e932d346bc5739379109d49e8853dd8223571c7c5b55260edc0b97f
11+
flit-core==3.12.0 \
12+
--hash=sha256:18f63100d6f94385c6ed57a72073443e1a71a4acb4339491615d0f16d6ff01b2 \
13+
--hash=sha256:e7a0304069ea895172e3c7bb703292e992c5d1555dd1233ab7b5621b5b69e62c
14+
# via -r build-requirements.in
15+
packaging==25.0 \
16+
--hash=sha256:29572ef2b1f17581046b3a2227d5c611fb25ec70ca1ba8554b24b0e69331a484 \
17+
--hash=sha256:d443872c98d677bf60f6a1f2f8c1cb748e8fe762d2bf9d3148b5599295b0fc4f
1418
# via build
1519
pyproject-hooks==1.2.0 \
1620
--hash=sha256:1e859bd5c40fae9448642dd871adf459e5e2084186e8d2c2a79a824c970da1f8 \
1721
--hash=sha256:9e5c6bfa8dcc30091c74b0cf803c81fdd29d94f01992a7707bc97babb1141913
1822
# via build
19-
20-
# The following packages are considered to be unsafe in a requirements file:
21-
setuptools==80.9.0 \
22-
--hash=sha256:062d34222ad13e0cc312a4c02d73f059e86a4acbfbdea8f8f76b28c99f306922 \
23-
--hash=sha256:f36b47402ecde768dbfafc46e8e4207b4360c654f1f3bb84475f0a28628fb19c
24-
# via -r build-requirements.in

docs/html/development/architecture/anatomy.rst

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ The ``README``, license, ``pyproject.toml``, and so on are in the top level.
1818

1919
* ``AUTHORS.txt``
2020
* ``LICENSE.txt``
21-
* ``MANIFEST.in``
2221
* ``NEWS.rst``
2322
* ``pyproject.toml``
2423
* ``README.rst``

pyproject.toml

Lines changed: 47 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
[project]
22
dynamic = ["version"]
3-
43
name = "pip"
54
description = "The PyPA recommended tool for installing Python packages."
65
readme = "README.rst"
@@ -45,31 +44,53 @@ Source = "https://github.com/pypa/pip"
4544
Changelog = "https://pip.pypa.io/en/stable/news/"
4645

4746
[build-system]
48-
requires = ["setuptools>=77"]
49-
build-backend = "setuptools.build_meta"
50-
51-
[tool.setuptools]
52-
package-dir = {"" = "src"}
53-
include-package-data = false
54-
55-
[tool.setuptools.dynamic]
56-
version = {attr = "pip.__version__"}
57-
58-
[tool.setuptools.packages.find]
59-
where = ["src"]
60-
exclude = ["contrib", "docs", "tests*", "tasks"]
61-
62-
[tool.setuptools.package-data]
63-
"pip" = ["py.typed"]
64-
"pip._vendor" = ["vendor.txt"]
65-
"pip._vendor.certifi" = ["*.pem"]
66-
"pip._vendor.distlib" = [
67-
"t32.exe",
68-
"t64.exe",
69-
"t64-arm.exe",
70-
"w32.exe",
71-
"w64.exe",
72-
"w64-arm.exe",
47+
requires = ["flit-core >=3.8,<4"]
48+
build-backend = "flit_core.buildapi"
49+
50+
[tool.flit.module]
51+
name = "pip"
52+
path = "src/pip"
53+
54+
[tool.flit.sdist]
55+
include = [
56+
"AUTHORS.txt",
57+
"LICENSE.txt",
58+
"NEWS.rst",
59+
"README.rst",
60+
"SECURITY.md",
61+
"pyproject.toml",
62+
"build-project/build-requirements.in",
63+
"build-project/build-requirements.txt",
64+
"build-project/build-project.py",
65+
"build-project/.python-version",
66+
"src/pip/_vendor/README.rst",
67+
"src/pip/_vendor/vendor.txt",
68+
"src/pip/_vendor/**/*LICENSE*",
69+
"src/pip/_vendor/**/*COPYING*",
70+
"docs/requirements.txt",
71+
"src/pip/_vendor/**/*.pem",
72+
"src/pip/_vendor/**/py.typed",
73+
"docs/**/*.css",
74+
"docs/**/*.py",
75+
"docs/**/*.rst",
76+
"docs/**/*.md",
77+
"docs/**/*.dot",
78+
"docs/**/*.png",
79+
]
80+
81+
exclude = [
82+
".git-blame-ignore-revs",
83+
".mailmap",
84+
".readthedocs.yml",
85+
".pre-commit-config.yaml",
86+
".readthedocs-custom-redirects.yml",
87+
"noxfile.py",
88+
"*.pyi",
89+
".github/**",
90+
"docs/build/**",
91+
"news/**",
92+
"tests/**",
93+
"tools/**",
7394
]
7495

7596
######################################################################################

0 commit comments

Comments
 (0)