Repository navigation
Add a script that releases to PyPI from a Docker container - #5
Merged
Merged
Conversation
docker-release.sh runs build.sh and release.sh in a clean python:3.12-slim container, so releasing doesn't depend on the local Python install. The source is mounted read-only and copied, and PyPI credentials come from ~/.pypirc or TWINE_USERNAME / TWINE_PASSWORD. It refuses to run with uncommitted changes, so what's uploaded matches a commit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
docker-release.shbuilds the package and uploads it to PyPI from a cleanpython:3.12-slimcontainer, so releasing doesn't depend on the Python install on the releasing machine. It runs the existingbuild.shandrelease.shunchanged.build/ordist/files in the checkout.~/.pypirc(mounted read-only) or theTWINE_USERNAME/TWINE_PASSWORDenvironment variables. When run from a terminal, twine can still ask for credentials.The README gets a short "Releasing" section.
This PR also adds the 0.1.26 release notes, covering the
payment_changedfix from #4 and this script. They missed #4 because it was merged before they were pushed.Testing
Tested in a throwaway local clone, with the upload line in
release.shreplaced by anechoand no~/.pypircavailable:django_askell-0.1.25(wheel and sdist) in the container,twine checkpassed for both, and it reached the upload step.build/ordist/afterwards.setup.pyit stopped with an error and exit code 1.The real upload hasn't been run.
🤖 Generated with Claude Code