|
1 |
| -name: "Build" |
| 1 | +name: Build |
2 | 2 |
|
3 | 3 | on:
|
4 | 4 | - push
|
5 | 5 | - pull_request
|
6 | 6 |
|
7 | 7 | jobs:
|
8 |
| - build: # Check build on various OSes |
9 |
| - |
| 8 | + build: |
10 | 9 | strategy:
|
| 10 | + fail-fast: false |
11 | 11 | matrix:
|
12 | 12 | os:
|
13 | 13 | - ubuntu-latest
|
14 | 14 | ocaml-compiler:
|
15 |
| - - 4.02.x |
16 |
| - - 4.04.x |
17 |
| - - 4.06.x |
18 |
| - - 4.08.x |
19 |
| - - 4.10.x |
20 |
| - - 4.12.x |
21 |
| - - 4.14.x |
22 |
| - - 5.0.x |
23 |
| - - 5.1.x |
| 15 | + - "4.02" |
| 16 | + - "4.04" |
| 17 | + - "4.06" |
| 18 | + - "4.08" |
| 19 | + - "4.10" |
| 20 | + - "4.12" |
| 21 | + - "4.14" |
| 22 | + - "5.0" |
| 23 | + - "5.2" |
24 | 24 | include:
|
25 | 25 | - os: ubuntu-latest
|
26 |
| - ocaml-compiler: 5.1.x |
| 26 | + ocaml-compiler: "5.2" |
27 | 27 | # We don't need to compute coverage for more than one build
|
28 | 28 | send-coverage: true
|
29 | 29 | # Mdx tests Mdx tests
|
30 | 30 | run-mdx: true
|
31 |
| - fail-fast: false |
| 31 | + - os: macos-latest |
| 32 | + ocaml-compiler: "5.2" |
| 33 | + # - os: windows-latest |
| 34 | + # ocaml-compiler: "5.2" |
32 | 35 |
|
33 | 36 | runs-on: ${{ matrix.os }}
|
34 | 37 |
|
35 | 38 | steps:
|
36 |
| - # Clone the project |
37 |
| - - uses: actions/checkout@v2 |
| 39 | + - name: Set git to use LF |
| 40 | + if: runner.os == 'Windows' |
| 41 | + run: | |
| 42 | + git config --global core.autocrlf false |
| 43 | + git config --global core.eol lf |
38 | 44 |
|
39 |
| - # Setup |
40 |
| - - name: Setup OCaml ${{ matrix.ocaml-version }} |
41 |
| - uses: ocaml/setup-ocaml@v2 |
| 45 | + - name: Checkout tree |
| 46 | + uses: actions/checkout@v4 |
| 47 | + |
| 48 | + - name: Set-up OCaml ${{ matrix.ocaml-compiler }} |
| 49 | + uses: ocaml/setup-ocaml@v3 |
42 | 50 | with:
|
43 |
| - # Do not pin odoc to not break Mdx installation |
44 |
| - opam-pin: false |
45 | 51 | ocaml-compiler: ${{ matrix.ocaml-compiler }}
|
46 |
| - opam-local-packages: | |
47 |
| - odoc.opam |
| 52 | + # Do not pin odoc to not break Mdx installation |
| 53 | + opam-pin: ${{ matrix.run-mdx != true }} |
48 | 54 |
|
49 | 55 | - name: Install dependencies
|
50 |
| - run: opam install -y --deps-only -t ./odoc.opam ./odoc-parser.opam |
| 56 | + run: opam install --deps-only --with-test ./odoc.opam ./odoc-parser.opam |
51 | 57 |
|
52 | 58 | - name: dune runtest
|
53 | 59 | run: opam exec -- dune runtest
|
54 | 60 |
|
55 | 61 | - name: Mdx tests
|
56 | 62 | if: matrix.run-mdx == true
|
57 | 63 | run: |
|
58 |
| - opam install -y mdx |
| 64 | + opam install mdx |
59 | 65 | opam exec -- dune build @runmdx
|
60 | 66 |
|
61 | 67 | - name: Send coverage stats to Coveralls
|
|
67 | 73 | opam exec -- bisect-ppx-report send-to Coveralls --coverage-path /tmp/coverage
|
68 | 74 | env:
|
69 | 75 | BISECT_FILE: /tmp/coverage/bisect
|
70 |
| - COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 76 | + COVERALLS_REPO_TOKEN: ${{ github.token }} |
71 | 77 | PULL_REQUEST_NUMBER: ${{ github.event.number }}
|
0 commit comments