forked from ocaml-ppx/ppxlib
-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (37 loc) · 1.14 KB
/
build.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
name: Build on `trunk`
on:
push:
pull_request:
schedule:
# Every weekday, at 5:43 UTC
- cron: '43 5 * * 1-5'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Pick up a robust cache prefix
id: setup
run: |
# Ensure that cache is flushed when trunk is updated
cache_prefix="$(git ls-remote https://github.com/ocaml/ocaml.git refs/heads/trunk | cut -f 1)"
echo "cache_prefix=$cache_prefix" >> "$GITHUB_OUTPUT"
cat "$GITHUB_OUTPUT"
- name: Install OCaml compiler
uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: 'ocaml-variants.5.2.0+trunk'
dune-cache: true
cache-prefix: ${{ steps.setup.outputs.cache_prefix }}
- name: Install ppxlib dependencies
run: |
opam install ./ppxlib.opam --deps-only
- name: Show configuration
run: |
opam exec -- ocamlc -config
opam config list
opam exec -- dune printenv
opam list
- name: Build the ppxlib
run: opam exec -- dune build -p ppxlib