Skip to content

Commit

Permalink
add github actions to publish on pypi (#25)
Browse files Browse the repository at this point in the history
  • Loading branch information
un4gt authored Sep 18, 2024
1 parent 3ae4b78 commit a9f42a8
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: publish to pypi

"on":
push:
tags:
- 'v*'
workflow_run:
workflows: ["Pre-Commit Check"]
types: completed
conclusion: success


jobs:
release_to_pypi:
name: Release to PyPI
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/bilifm
permissions:
id-token: write
contents: write
steps:
- uses: actions/checkout@v4
- name: Setup pdm
id: setup-pdm
uses: pdm-project/setup-pdm@v4
- name: Check output
run: |
echo ${{ steps.setup-pdm.outputs.pdm-bin }}
echo ${{ steps.setup-pdm.outputs.pdm-version }}
echo ${{ steps.setup-pdm.outputs.python-path }}
echo ${{ steps.setup-pdm.outputs.python-version }}
- name: pypi-publish-by-pdm
run: pdm publish

0 comments on commit a9f42a8

Please sign in to comment.