|
| 1 | +# Run "make all" on selected Ubuntu and Python versions. |
| 2 | + |
| 3 | +name: make all |
| 4 | + |
| 5 | +# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows |
| 6 | +on: |
| 7 | + # Trigger workflow on push event. |
| 8 | + #push: |
| 9 | + # branches: [ ci ] |
| 10 | + |
| 11 | + # Trigger workflow on pull request. |
| 12 | + # pull_request: |
| 13 | + # branches: [ ci ] |
| 14 | + |
| 15 | + # Trigger workflow in GitHub web frontend or from API. |
| 16 | + workflow_dispatch: |
| 17 | + inputs: |
| 18 | + os: |
| 19 | + description: 'Operating system' |
| 20 | + required: true |
| 21 | + default: any |
| 22 | + type: choice |
| 23 | + options: |
| 24 | + - any |
| 25 | + - ubuntu-18.04 |
| 26 | + - ubuntu-20.04 |
| 27 | + python-version: |
| 28 | + description: 'Python version' |
| 29 | + required: true |
| 30 | + default: any |
| 31 | + type: choice |
| 32 | + options: |
| 33 | + - any |
| 34 | + - '3.6' |
| 35 | + - '3.7' |
| 36 | + - '3.8' |
| 37 | + - '3.9' |
| 38 | + - '3.10' |
| 39 | + |
| 40 | +jobs: |
| 41 | + # Run builds for all Ubuntu and Python versions. |
| 42 | + build-any: |
| 43 | + # https://docs.github.com/en/actions/learn-github-actions/expressions |
| 44 | + if: ${{ (github.event.inputs.os == 'any') && (github.event.inputs.python-version == 'any') || (github.event.inputs.os == '') }} |
| 45 | + uses: ./.github/workflows/makeall-linux.yaml |
| 46 | + with: |
| 47 | + os: "[\'ubuntu-18.04\', \'ubuntu-20.04\']" |
| 48 | + python-version: "['3.6', '3.7', '3.8', '3.9', '3.10']" |
| 49 | + |
| 50 | + # Run builds for all Ubuntu versions and selected Python version. |
| 51 | + build-any-os: |
| 52 | + if: ${{ (github.event.inputs.os == 'any') && (github.event.inputs.python-version != 'any') }} |
| 53 | + uses: ./.github/workflows/makeall-linux.yaml |
| 54 | + with: |
| 55 | + os: "[\'ubuntu-18.04\', \'ubuntu-20.04\']" |
| 56 | + python-version: "[\'${{ github.event.inputs.python-version }}\']" |
| 57 | + |
| 58 | + # Run builds for selected Ubuntu version and all Python versions. |
| 59 | + build-any-python: |
| 60 | + if: ${{ (github.event.inputs.os != 'any') && (github.event.inputs.python-version == 'any') }} |
| 61 | + uses: ./.github/workflows/makeall-linux.yaml |
| 62 | + with: |
| 63 | + os: "[\'${{ github.event.inputs.os }}\']" |
| 64 | + python-version: "['3.6', '3.7', '3.8', '3.9', '3.10']" |
| 65 | + |
| 66 | + # Run builds for selected Ubuntu and Python versions. |
| 67 | + build: |
| 68 | + if: ${{ (github.event.inputs.os != 'any') && (github.event.inputs.python-version != 'any') && (github.event.inputs.os != '') }} |
| 69 | + uses: ./.github/workflows/makeall-linux.yaml |
| 70 | + with: |
| 71 | + os: "[\'${{ github.event.inputs.os }}\']" |
| 72 | + python-version: "[\'${{ github.event.inputs.python-version }}\']" |
0 commit comments