-
Notifications
You must be signed in to change notification settings - Fork 147
58 lines (53 loc) · 1.84 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: build
on: [push, pull_request]
jobs:
ubuntu-24_04:
runs-on: ubuntu-24.04
if: false # XXX unreliable
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/*