-
Notifications
You must be signed in to change notification settings - Fork 38
41 lines (39 loc) · 1.03 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
name: Build
on: [push, pull_request]
jobs:
tox:
strategy:
matrix:
os:
- 'ubuntu-latest'
python-version:
- '3.7'
- '3.8'
- '3.9'
- '3.10'
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
# Need full history to determine version number.
fetch-depth: 0
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Python packaging/test tools
run: python -m pip install tox wheel
- name: Show package version
run: python setup.py --version
- name: Test with tox
run: tox
- name: Build wheel
run: python setup.py bdist_wheel
- name: Upload wheels as artifacts
uses: actions/upload-artifact@v4
if: ${{ runner.os == 'Linux' && matrix.python-version == '3.9' }}
with:
name: python-packages
path: |
dist/*.whl
dist/*.tar.gz