Skip to content

Commit

Permalink
github workflow: added publish tags to pypi
Browse files Browse the repository at this point in the history
  • Loading branch information
vgavro committed Jul 23, 2024
1 parent 1170259 commit cb765f1
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Publish

on:
push:
tags:
- 'v*'

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v3
with:
python-version: 3.11

- run: |
pip install setuptools wheel
python setup.py sdist bdist_wheel
- uses: actions/upload-artifact@v3
with:
path: ./dist

pypi-publish:
needs: ['build']
environment:
name: publish
url: https://pypi.org/p/python-samsung-mdc

name: Upload release to PyPI
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- uses: actions/download-artifact@v3

- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages_dir: artifact/

0 comments on commit cb765f1

Please sign in to comment.