Skip to content

ci: publish to PyPI (OIDC) and crates.io on release tags#28

Merged
rafaelperoco merged 1 commit into
mainfrom
chore/pypi-crates-publish-jobs
May 3, 2026
Merged

ci: publish to PyPI (OIDC) and crates.io on release tags#28
rafaelperoco merged 1 commit into
mainfrom
chore/pypi-crates-publish-jobs

Conversation

@rafaelperoco
Copy link
Copy Markdown
Owner

Closes part of #13.

Adds two jobs to release.yml so that pushing vX.Y.Z also publishes:

  • PyPI: trusted publishing via OIDC. No long-lived token; the GitHub Actions identity is the credential. Configures via the pypi deployment environment.
  • crates.io: token-based, gated on CRATES_TOKEN repo secret. Job no-ops with a clear message when the secret is absent.

The pre-release tag form (v2.0.0-alpha.1) is translated to PEP 440 (2.0.0a1) before pyproject.toml is rewritten — semver pre-release suffixes are not valid PEP 440. cargo accepts SemVer 2.0 directly so no translation is needed.

CONTRIBUTING.md gains a registry table documenting the one-time setup for each registry. The first publish on each must be done manually to reserve the name; subsequent publishes ride this pipeline.

@rafaelperoco rafaelperoco force-pushed the chore/pypi-crates-publish-jobs branch from e822811 to bca2e2a Compare May 3, 2026 19:10
@rafaelperoco rafaelperoco merged commit 920840d into main May 3, 2026
12 checks passed
@rafaelperoco rafaelperoco deleted the chore/pypi-crates-publish-jobs branch May 3, 2026 19:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant