Skip to content

Commit

Permalink
👷 update release ci
Browse files Browse the repository at this point in the history
  • Loading branch information
yanyongyu authored Feb 12, 2024
1 parent 7504590 commit 95c932c
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ on:
jobs:
release:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write
steps:
- uses: actions/checkout@v3

Expand All @@ -25,10 +28,13 @@ jobs:
if: steps.version.outputs.VERSION != steps.version.outputs.TAG_VERSION
run: exit 1

- name: Build and Publish Package
run: |
poetry build
poetry publish -u ${{ secrets.PYPI_USERNAME }} -p ${{ secrets.PYPI_PASSWORD }}
gh release upload --clobber ${{ steps.version.outputs.TAG_NAME }} dist/*.tar.gz dist/*.whl
- name: Build
run: poetry build

- name: Publish a Python distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1

- name: Upload Release Asset
run: gh release upload --clobber ${{ steps.version.outputs.TAG_NAME }} dist/*.tar.gz dist/*.whl
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 95c932c

Please sign in to comment.