|
8 | 8 | - master |
9 | 9 | release: |
10 | 10 | types: published |
| 11 | + |
11 | 12 | jobs: |
12 | 13 | tar_gz: |
13 | 14 | name: Package |
14 | 15 | runs-on: ubuntu-latest |
15 | 16 | steps: |
16 | | - - uses: actions/checkout@v2 |
17 | | - - uses: actions/setup-python@v2 |
| 17 | + - uses: actions/checkout@v3 |
| 18 | + - uses: actions/setup-python@v3 |
18 | 19 | - run: python setup.py sdist |
19 | | - - uses: actions/upload-artifact@v2 |
| 20 | + - uses: actions/upload-artifact@v3 |
20 | 21 | with: |
21 | 22 | name: dist |
22 | 23 | path: dist |
23 | | - whl: |
| 24 | + |
| 25 | + whl_lt_3_9: |
24 | 26 | name: Build / ${{ matrix.os }} / Python 3.${{ matrix.minor }} |
25 | 27 | strategy: |
26 | 28 | fail-fast: false |
27 | 29 | matrix: |
28 | 30 | os: [macOS, Ubuntu, Windows] |
29 | | - minor: [7, 8, 9, 10, 11] |
| 31 | + minor: [7, 8] |
30 | 32 | runs-on: ${{ matrix.os }}-latest |
31 | 33 | steps: |
32 | | - - uses: actions/checkout@v2 |
33 | | - - uses: actions/setup-python@v2 |
| 34 | + - uses: actions/checkout@v3 |
| 35 | + - uses: actions/setup-python@v3 |
34 | 36 | - uses: pypa/cibuildwheel@v2.11.2 |
35 | 37 | with: |
36 | 38 | output-dir: dist |
37 | 39 | env: |
38 | 40 | CIBW_BUILD: cp3${{ matrix.minor }}-* |
39 | 41 | CIBW_ARCHS_MACOS: all |
| 42 | + CIBW_BEFORE_BUILD: pip install -r {project}/requirements-build-backward.txt |
| 43 | + CIBW_BEFORE_TEST: pip install -r {project}/requirements-backward.txt |
| 44 | + CIBW_TEST_COMMAND: pytest {project} |
| 45 | + |
| 46 | + - uses: actions/upload-artifact@v3 |
| 47 | + with: |
| 48 | + name: dist |
| 49 | + path: dist |
| 50 | + |
| 51 | + whl_gte_3_9: |
| 52 | + name: Build / ${{ matrix.os }} / Python 3.${{ matrix.minor }} |
| 53 | + strategy: |
| 54 | + fail-fast: false |
| 55 | + matrix: |
| 56 | + os: [macOS, Ubuntu, Windows] |
| 57 | + minor: [9, 10, 11] |
| 58 | + runs-on: ${{ matrix.os }}-latest |
| 59 | + steps: |
| 60 | + - uses: actions/checkout@v3 |
| 61 | + - uses: actions/setup-python@v3 |
| 62 | + - uses: pypa/cibuildwheel@v2.11.2 |
| 63 | + with: |
| 64 | + output-dir: dist |
| 65 | + env: |
| 66 | + CIBW_BUILD: cp3${{ matrix.minor }}-* |
| 67 | + CIBW_ARCHS_MACOS: all |
| 68 | + CIBW_BEFORE_BUILD: pip install -r {project}/requirements-build.txt |
40 | 69 | CIBW_BEFORE_TEST: pip install -r {project}/requirements.txt |
41 | 70 | CIBW_TEST_COMMAND: pytest {project} |
42 | | - - uses: actions/upload-artifact@v2 |
| 71 | + |
| 72 | + - uses: actions/upload-artifact@v3 |
43 | 73 | with: |
44 | 74 | name: dist |
45 | 75 | path: dist |
| 76 | + |
46 | 77 | upload: |
47 | 78 | name: Publish |
48 | 79 | if: github.event_name == 'release' && github.event.action == 'published' |
49 | | - needs: [tar_gz, whl] |
| 80 | + needs: [tar_gz, whl_lt_3_9, whl_gte_3_9] |
50 | 81 | runs-on: ubuntu-latest |
51 | 82 | steps: |
52 | 83 | - uses: actions/download-artifact@v2 |
|
0 commit comments