Skip to content

Bump version and update deps #30

Bump version and update deps

Bump version and update deps #30

Workflow file for this run

name: Build
on: push
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
runs-on: ${{ matrix.os }}
steps:
#----------------------------------------------
# check-out repo and set-up python and poetry
#----------------------------------------------
- name: Checkout
uses: actions/checkout@v3
- name: Install poetry
run: pipx install poetry
- name: Setup Python 3
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'poetry'
- name: Install project
run: poetry install --no-interaction
- name: Run tests
run: poetry run python -m unittest tests
build:
needs: test
runs-on: ubuntu-latest
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
steps:
#----------------------------------------------
# check-out repo and set-up python and poetry
#----------------------------------------------
- name: Checkout
uses: actions/checkout@v3
- name: Install poetry
run: pipx install poetry
- name: Setup Python 3
uses: actions/setup-python@v4
with:
python-version: '3.x'
cache: 'poetry'
- name: Build
run: poetry build --ansi --no-interaction
- uses: actions/upload-artifact@v2
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
with:
name: dist
path: dist
release:
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install poetry
run: pipx install poetry
- name: Setup Python 3
uses: actions/setup-python@v4
with:
python-version: '3.x'
cache: 'poetry'
- uses: actions/download-artifact@v2
with:
name: dist
path: dist
- name: Generate Changelog
id: changelog
uses: mikepenz/release-changelog-builder-action@v3
with:
owner: iamkroot
ignorePreReleases: true
commitMode: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Release(github)
if: ${{ ! env.ACT }}
uses: softprops/action-gh-release@v1
with:
files: dist/*.*
body: ${{steps.github_release.outputs.changelog}}
- name: Release(pypi)
run: poetry publish --ansi --no-interaction
env:
POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_TOKEN }}
# vim:ft=yaml:ts=2:et: