Skip to content

Commit

Permalink
Merge pull request #1307 from chrysle/gh-actions-guide-create-release
Browse files Browse the repository at this point in the history
Add step to create empty GH Release before upload
  • Loading branch information
webknjaz committed Oct 24, 2023
2 parents 576220c + d14e4e6 commit 4303d21
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,11 @@ jobs:
inputs: >-
./dist/*.tar.gz
./dist/*.whl
- name: Create GitHub Release
run: >-
gh release create
'${{ github.ref_name }}'
--notes ""
- name: Upload artifact signatures to GitHub Release
env:
GITHUB_TOKEN: ${{ github.token }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,13 @@ Signing the distribution packages
The following job signs the distribution packages with `Sigstore`_,
the same artifact signing system `used to sign CPython <https://www.python.org/download/sigstore/>`_.

It uses the `sigstore/gh-action-sigstore-python GitHub Action`_,
and then uploads them to a GitHub Release.
Firstly, it uses the `sigstore/gh-action-sigstore-python GitHub Action`_
to sign the distribution packages. In the next step, an empty GitHub Release
from the current tag is created using the ``gh`` CLI. Note this step can be further
customised. See the `gh release documentation <https://cli.github.com/manual/gh_release>`_
as a reference.

Finally, the signed distributions are uploaded to the GitHub Release.

.. literalinclude:: github-actions-ci-cd-sample/publish-to-test-pypi.yml
:language: yaml
Expand Down

0 comments on commit 4303d21

Please sign in to comment.