From f85c0f7a14da570c3a5bcbcc443ab9040a94b735 Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Fri, 25 Nov 2022 12:01:49 +0100 Subject: [PATCH 1/2] Most of `MANIFEST.in` is obsolete, get rid of it https://github.com/pypa/setuptools_scm Additionally `setuptools_scm` provides setuptools with a list of files that are managed by the SCM (i.e. it automatically adds all of the SCM-managed files to the sdist). Unwanted files must be excluded by discarding them via `MANIFEST.in`. --- MANIFEST.in | 7 +------ Makefile | 7 ++----- pyproject.toml | 4 ---- 3 files changed, 3 insertions(+), 15 deletions(-) diff --git a/MANIFEST.in b/MANIFEST.in index 60957b16d9..36e8cf9628 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,12 +1,7 @@ -include codespell_lib/__init__.py -recursive-include codespell_lib *.py -include codespell_lib/data/dictionary*.txt -include codespell_lib/data/linux-kernel.exclude -include COPYING exclude *.yml *.yaml exclude .coveragerc exclude .git-blame-ignore-revs -exclude example example/* snap snap/* tools tools/* +exclude example example/* snap snap/* exclude Makefile exclude codespell.1.include exclude pyproject-codespell.precommit-toml diff --git a/Makefile b/Makefile index fbe9814649..88e6203522 100644 --- a/Makefile +++ b/Makefile @@ -2,11 +2,11 @@ SORT_ARGS := -f -b DICTIONARIES := codespell_lib/data/dictionary*.txt -PHONY := all check check-dictionaries sort-dictionaries trim-dictionaries check-dictionary sort-dictionary trim-dictionary check-manifest check-dist flake8 pytest pypi clean +PHONY := all check check-dictionaries sort-dictionaries trim-dictionaries check-dictionary sort-dictionary trim-dictionary check-dist flake8 pytest pypi clean all: check-dictionaries codespell.1 -check: check-dictionaries check-manifest check-dist flake8 pytest +check: check-dictionaries check-dist flake8 pytest check-dictionary: check-dictionaries sort-dictionary: sort-dictionaries @@ -44,9 +44,6 @@ trim-dictionaries: sed -E -i.bak -e 's/^[[:space:]]+//; s/[[:space:]]+$$//; /^$$/d' $$dictionary && rm $$dictionary.bak; \ done -check-manifest: - check-manifest --no-build-isolation - check-dist: $(eval TMP := $(shell mktemp -d)) python -m build -o $(TMP) diff --git a/pyproject.toml b/pyproject.toml index 4dc98082c8..fa27cf3ff0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -32,7 +32,6 @@ dynamic = ["version"] [project.optional-dependencies] dev = [ - "check-manifest", "flake8", "flake8-pyproject", "pytest", @@ -91,9 +90,6 @@ expand-star-imports = true skip = "B101,B404,B603" recursive = true -[tool.check-manifest] -ignore = ["codespell_lib/_version.py"] - # TODO: reintegrate codespell configuration after updating test cases #[tool.codespell] #builtin = ["clear","rare","informal","usage","code","names"] From 0309137b98c48d42129482616f10e19d997dcfbc Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Mon, 28 Nov 2022 17:43:28 +0100 Subject: [PATCH 2/2] Add `build` as a dependancy Required after ba4e71d, which introduced `python -m build`. --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index fa27cf3ff0..3729f5df82 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -32,6 +32,7 @@ dynamic = ["version"] [project.optional-dependencies] dev = [ + "build", "flake8", "flake8-pyproject", "pytest",