|
| 1 | +name: CI |
| 2 | + |
| 3 | +on: |
| 4 | + push: |
| 5 | + branches: |
| 6 | + - main |
| 7 | + - dev |
| 8 | + - 'releases/**' |
| 9 | + tags: '*' |
| 10 | + pull_request: |
| 11 | + release: |
| 12 | + |
| 13 | +concurrency: |
| 14 | + # Skip intermediate builds: always. |
| 15 | + # Cancel intermediate builds: only if it is a pull request build. |
| 16 | + group: ${{ github.workflow }}-${{ github.ref }} |
| 17 | + cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }} |
| 18 | + |
| 19 | +jobs: |
| 20 | + test: |
| 21 | + name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} |
| 22 | + runs-on: ${{ matrix.os }} |
| 23 | + continue-on-error: ${{ matrix.version == 'nightly' }} |
| 24 | + strategy: |
| 25 | + fail-fast: false |
| 26 | + matrix: |
| 27 | + version: |
| 28 | + - '1.6' |
| 29 | + - '1' |
| 30 | + # - 'nightly' |
| 31 | + os: |
| 32 | + - ubuntu-latest |
| 33 | + arch: |
| 34 | + - x64 |
| 35 | + include: |
| 36 | + - version: 1 |
| 37 | + os: ubuntu-latest |
| 38 | + arch: x86 |
| 39 | + - version: 1 |
| 40 | + os: macOS-latest |
| 41 | + arch: x64 |
| 42 | + - version: 1 |
| 43 | + os: windows-latest |
| 44 | + arch: x64 |
| 45 | + steps: |
| 46 | + - uses: actions/checkout@v2 |
| 47 | + - uses: julia-actions/setup-julia@latest |
| 48 | + with: |
| 49 | + version: ${{ matrix.version }} |
| 50 | + arch: ${{ matrix.arch }} |
| 51 | + - name: Cache artifacts |
| 52 | + uses: actions/cache@v2 |
| 53 | + env: |
| 54 | + cache-name: cache-artifacts |
| 55 | + with: |
| 56 | + path: ~/.julia/artifacts |
| 57 | + key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} |
| 58 | + restore-keys: | |
| 59 | + ${{ runner.os }}-test-${{ env.cache-name }}- |
| 60 | + ${{ runner.os }}-test- |
| 61 | + ${{ runner.os }}- |
| 62 | + - uses: julia-actions/julia-buildpkg@latest |
| 63 | + env: |
| 64 | + PYTHON: 'Conda' |
| 65 | + - uses: julia-actions/julia-runtest@latest |
| 66 | + with: |
| 67 | + coverage: ${{ matrix.version == '1' && matrix.os == 'ubuntu-latest' && matrix.arch == 'x64' }} |
| 68 | + - uses: julia-actions/julia-processcoverage@v1 |
| 69 | + if: matrix.version == '1' && matrix.os == 'ubuntu-latest' && matrix.arch == 'x64' |
| 70 | + - uses: codecov/codecov-action@v1 |
| 71 | + if: matrix.version == '1' && matrix.os == 'ubuntu-latest' && matrix.arch == 'x64' |
| 72 | + with: |
| 73 | + file: lcov.info |
| 74 | + docs: |
| 75 | + name: Documentation |
| 76 | + runs-on: ubuntu-latest |
| 77 | + steps: |
| 78 | + - uses: actions/checkout@v2 |
| 79 | + - uses: julia-actions/setup-julia@latest |
| 80 | + with: |
| 81 | + version: '1' |
| 82 | + - name: Cache artifacts |
| 83 | + uses: actions/cache@v2 |
| 84 | + env: |
| 85 | + cache-name: cache-artifacts |
| 86 | + with: |
| 87 | + path: ~/.julia/artifacts |
| 88 | + key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/docs/Project.toml') }} |
| 89 | + restore-keys: | |
| 90 | + ${{ runner.os }}-test-${{ env.cache-name }}- |
| 91 | + ${{ runner.os }}-test- |
| 92 | + ${{ runner.os }}- |
| 93 | + - uses: julia-actions/julia-buildpkg@latest |
| 94 | + env: |
| 95 | + PYTHON: 'Conda' |
| 96 | + - uses: julia-actions/julia-docdeploy@latest |
| 97 | + env: |
| 98 | + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 99 | + # Needed due to https://github.com/JuliaDocs/Documenter.jl/issues/1177 |
| 100 | + DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} |
| 101 | + GKSwstype: 'nul' |
0 commit comments