github: Test on Ubuntu 24.04 too. #76
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: [push, pull_request] | |
jobs: | |
ubuntu-24_04: | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
- name: apt-update | |
run: sudo apt-get update -qq | |
- name: apt-install | |
run: sudo apt-get install -qq -y --no-install-recommends gir1.2-gtk-3.0 python3-gi python3-gi-cairo python3-numpy python3-packaging python3-setuptools graphviz xvfb twine | |
- name: build | |
run: python3 setup.py sdist | |
- name: test | |
run: .github/scripts/test.sh | |
ubuntu-22_04: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
- name: apt-update | |
run: sudo apt-get update -qq | |
- name: apt-install | |
run: sudo apt-get install -qq -y --no-install-recommends gir1.2-gtk-3.0 python3-gi python3-gi-cairo python3-numpy python3-packaging python3-setuptools graphviz xvfb twine | |
- name: build | |
run: python3 setup.py sdist | |
- name: test | |
run: .github/scripts/test.sh | |
ubuntu-20_04: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
- name: apt-update | |
run: sudo apt-get update -qq | |
- name: apt-install | |
run: sudo apt-get install -qq -y --no-install-recommends gir1.2-gtk-3.0 python3-gi python3-gi-cairo python3-numpy python3-packaging python3-setuptools graphviz xvfb twine | |
- name: build | |
run: python3 setup.py sdist | |
- name: test | |
run: .github/scripts/test.sh | |
# https://docs.github.com/en/actions/guides/building-and-testing-python#publishing-to-package-registries | |
- name: publish-pypi | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') | |
env: | |
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} | |
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} | |
run: twine upload dist/* |