Skip to content

0.16.0

0.16.0 #50

Workflow file for this run

name: Publish Python Package
on:
release:
types: [created]
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
steps:
- uses: actions/checkout@v3
with:
submodules: "recursive"
- name: submodules recursively
run: git submodule foreach git pull origin main --depth 9999
- name: Setup FFmpeg
uses: FedericoCarboni/setup-ffmpeg@v2
- name: Install libsndfile
run: sudo apt-get install -y libsndfile1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tensorflow librosa soundfile pytest mock
pip install .
# if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Test with pytest
run: |
pytest -m "not omit_during_ghactions"
deploy:
runs-on: ubuntu-latest
needs: [test]
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install dependencies
run: |
pip install setuptools wheel twine build
- name: Publish
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
run: |
python -m build
twine upload dist/*
# twine upload --repository-url https://test.pypi.org/legacy/ dist/*