-
Notifications
You must be signed in to change notification settings - Fork 1
chore: simplify the release process #72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 4 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
1fb9ba1
chore: simplify the release process
WilliamBergamin a708632
Potential fix for code scanning alert no. 1: Workflow does not contai…
WilliamBergamin d0c8ce5
Update maintainers_guide.md
WilliamBergamin 10935e8
Merge branch 'publish-to-test-pypi-with-oidc' of https://github.com/s…
WilliamBergamin f60e8da
Apply suggestions from code review
WilliamBergamin fb67383
Apply suggestions from code review
WilliamBergamin 24f2021
ensure consistency
WilliamBergamin File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| # https://docs.github.com/en/repositories/releasing-projects-on-github/automatically-generated-release-notes#configuring-automatically-generated-release-notes | ||
| changelog: | ||
| categories: | ||
| - title: 🚀 Enhancements | ||
| labels: | ||
| - enhancement | ||
| - title: 🐛 Bug Fixes | ||
| labels: | ||
| - bug | ||
| - title: 📚 Documentation | ||
| labels: | ||
| - docs | ||
|
Comment on lines
+10
to
+12
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔍 note: Not all of our projects have matching labels at the moment... I believe we're moving toward "docs" but we might want to follow up later to make sure projects match here! |
||
| - title: 🤖 Build | ||
| labels: | ||
| - build | ||
| - title: 🧪 Testing/Code Health | ||
| labels: | ||
| - code health | ||
| - title: 🔒 Security | ||
| labels: | ||
| - security | ||
| - title: 📦 Other changes | ||
| labels: | ||
| - "*" | ||
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,85 @@ | ||
| name: Upload A Release to pypi.org or test.pypi.org | ||
|
|
||
| on: | ||
| release: | ||
| types: | ||
| - published | ||
| workflow_dispatch: | ||
| inputs: | ||
| dry_run: | ||
| description: "Dry run (build only, do not publish)" | ||
| required: false | ||
| type: boolean | ||
| default: false | ||
|
|
||
| jobs: | ||
| release-build: | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | ||
| with: | ||
| persist-credentials: false | ||
|
|
||
| - name: Set up Python | ||
| uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 | ||
| with: | ||
| python-version: "3.x" | ||
|
|
||
| - name: Build release distributions | ||
| run: | | ||
| scripts/build_pypi_package.sh | ||
| - name: Persist dist folder | ||
| uses: actions/upload-artifact@v4 | ||
WilliamBergamin marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| with: | ||
| name: release-dist | ||
| path: dist/ | ||
|
|
||
| test-pypi-publish: | ||
| runs-on: ubuntu-latest | ||
| needs: | ||
| - release-build | ||
| if: github.event_name == 'workflow_dispatch' && !github.event.inputs.dry_run | ||
WilliamBergamin marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| environment: | ||
| name: testpypi | ||
| permissions: | ||
| id-token: write | ||
|
|
||
| steps: | ||
| - name: Retrieve dist folder | ||
| uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 | ||
| with: | ||
| name: release-dist | ||
| path: dist/ | ||
|
|
||
| - name: Publish release distributions to test.pypi.org | ||
| # Using OIDC for PyPI publishing (no API tokens needed) | ||
| # See: https://docs.github.com/en/actions/how-tos/secure-your-work/security-harden-deployments/oidc-in-pypi | ||
| uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0 | ||
| with: | ||
| repository-url: https://test.pypi.org/legacy/ | ||
|
|
||
| pypi-publish: | ||
| runs-on: ubuntu-latest | ||
| needs: | ||
| - release-build | ||
| if: github.event_name == 'release' | ||
| environment: | ||
| name: pypi | ||
| permissions: | ||
| id-token: write | ||
|
|
||
| steps: | ||
| - name: Retrieve dist folder | ||
| uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 | ||
| with: | ||
| name: release-dist | ||
| path: dist/ | ||
|
|
||
| - name: Publish release distributions to test.pypi.org | ||
| # Using OIDC for PyPI publishing (no API tokens needed) | ||
| # See: https://docs.github.com/en/actions/how-tos/secure-your-work/security-harden-deployments/oidc-in-pypi | ||
| uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0 | ||
This file was deleted.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
⭐ praise: Nice! These notes are so useful for the unfamiliar reader!