2024-04-17 19:47:40 +00:00
|
|
|
name: Deploy Python Package
|
2024-04-18 08:07:12 +00:00
|
|
|
on: [push]
|
2024-04-17 19:47:40 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
deploy:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
2024-04-17 19:55:02 +00:00
|
|
|
|
|
|
|
- name: Set up Python 3.11
|
|
|
|
uses: actions/setup-python@v5
|
2024-04-17 19:47:40 +00:00
|
|
|
with:
|
2024-04-17 19:55:02 +00:00
|
|
|
python-version: "3.11"
|
|
|
|
|
|
|
|
- name: Install Linux dependencies
|
|
|
|
run: |
|
|
|
|
sudo apt install -y portaudio19-dev libhamlib-dev libhamlib-utils build-essential cmake python3-libhamlib2 patchelf
|
|
|
|
|
|
|
|
- name: Install Python dependencies
|
|
|
|
run: |
|
|
|
|
python -m pip install --upgrade pip
|
|
|
|
pip install -r requirements.txt
|
|
|
|
pip install wheel
|
2024-04-17 19:47:40 +00:00
|
|
|
|
|
|
|
- name: Build package
|
|
|
|
run: |
|
2024-04-17 19:55:02 +00:00
|
|
|
python setup.py sdist bdist_wheel
|
2024-04-17 19:47:40 +00:00
|
|
|
|
|
|
|
- name: Publish to PyPI
|
|
|
|
uses: pypa/gh-action-pypi-publish@v1.4.2
|
|
|
|
with:
|
|
|
|
user: __token__
|
|
|
|
password: ${{ secrets.PYPI_API_TOKEN }}
|