Skip to content
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

Update python-client action workflow #1479

Merged
merged 12 commits into from
Feb 8, 2024
21 changes: 13 additions & 8 deletions .github/workflows/pythonpublish.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,31 @@
name: Publish python-client

on:
workflow_dispatch: # Manual trigger
on: workflow_dispatch # Manual trigger

jobs:
deploy:
build_and_deploy:
name: Create and publish package to PyPI
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v3
uses: actions/setup-python@v4
with:
python-version: '3.8'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine

- name: Build and publish
working-directory: ./metaspace/python-client
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYTHON_CLIENT_PYPI_API_TOKEN }}
run: |
python setup.py sdist bdist_wheel
twine upload dist/*
twine upload dist/*
Loading