diff --git a/.changeset/update_pdm_metadata_syntax.md b/.changeset/update_pdm_metadata_syntax.md new file mode 100644 index 000000000..110af6620 --- /dev/null +++ b/.changeset/update_pdm_metadata_syntax.md @@ -0,0 +1,8 @@ +--- +default: major +--- + +# Update PDM metadata syntax + +Metadata generated for PDM will now use the new `distribution = true` syntax instead of `package-type = "library"`. +New packages generated will require PDM `2.12.0` or later to build. diff --git a/.gitignore b/.gitignore index 3c0fc0a41..5689da19b 100644 --- a/.gitignore +++ b/.gitignore @@ -4,6 +4,7 @@ build/ dist/ *.egg-info/ .pytest_cache/ +.ruff_cache # macOS .DS_Store diff --git a/end_to_end_tests/metadata_snapshots/pdm.pyproject.toml b/end_to_end_tests/metadata_snapshots/pdm.pyproject.toml index d020a3d27..fddcea97f 100644 --- a/end_to_end_tests/metadata_snapshots/pdm.pyproject.toml +++ b/end_to_end_tests/metadata_snapshots/pdm.pyproject.toml @@ -12,7 +12,7 @@ dependencies = [ ] [tool.pdm] -package-type = "library" +distribution = true [build-system] requires = ["pdm-backend"] diff --git a/integration-tests/pyproject.toml b/integration-tests/pyproject.toml index 0d4b2c73d..67b0d7f52 100644 --- a/integration-tests/pyproject.toml +++ b/integration-tests/pyproject.toml @@ -12,7 +12,7 @@ dependencies = [ requires-python = ">=3.8,<4.0" [tool.pdm] -package-type = "library" +distribution = true [tool.pdm.dev-dependencies] dev = [ diff --git a/openapi_python_client/templates/pyproject.toml.jinja b/openapi_python_client/templates/pyproject.toml.jinja index f836bff19..7f68d58e5 100644 --- a/openapi_python_client/templates/pyproject.toml.jinja +++ b/openapi_python_client/templates/pyproject.toml.jinja @@ -25,7 +25,7 @@ dependencies = [ ] [tool.pdm] -package-type = "library" +distribution = true {% endif %} {% if poetry %}