Copy LICENSE file into generated stub packages

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Joseph HENRY 2026-03-31 17:00:54 +02:00
parent 9e69eada48
commit 40b2742b91

View File

@ -313,6 +313,11 @@ def generate_package_files(
) )
(output_dir / "README.md").write_text(readme) (output_dir / "README.md").write_text(readme)
# Copy LICENSE file from the project root
license_src = SCRIPT_DIR / "LICENSE"
if license_src.exists():
shutil.copy2(license_src, output_dir / "LICENSE")
# Add py.typed marker to each top-level package so mypy recognizes the stubs # Add py.typed marker to each top-level package so mypy recognizes the stubs
for pkg in top_level_packages: for pkg in top_level_packages:
(output_dir / pkg / "py.typed").touch() (output_dir / pkg / "py.typed").touch()