forked from ocaml-ppx/ocamlformat
-
Notifications
You must be signed in to change notification settings - Fork 14
52 lines (41 loc) · 1.18 KB
/
build-linux.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
42
43
44
45
46
47
48
49
50
51
52
name: Build on Linux
# Build and run tests on ubuntu-latest.
on:
push:
branches:
- main
- jane
pull_request:
workflow_dispatch:
jobs:
build-linux:
strategy:
fail-fast: false
matrix:
ocaml-compiler:
# Don't include every versions. OCaml-CI already covers that
- 5.2.x
runs-on: ubuntu-latest
steps:
# Clone the project
- uses: actions/checkout@v2
with:
# Don't checkout the implicit merge commit to avoid wrong substitution
ref: ${{ github.event.pull_request.head.sha }}
# Setup
- name: Setup OCaml ${{ matrix.ocaml-version }}
uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: ${{ matrix.ocaml-compiler }}
- name: Opam dependencies
run: opam install --deps-only -t .
- name: Self-formatting test
run: opam exec -- dune build @fmt
- name: Build
run: |
opam exec -- dune subst
opam exec -- dune build -p ocamlformat-lib,ocamlformat
- name: Runtest
run: opam exec -- dune runtest
- name: Check manpages
run: opam exec -- dune build @gen_manpage --auto-promote