-
Notifications
You must be signed in to change notification settings - Fork 17
78 lines (63 loc) · 2.29 KB
/
blank.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Build
on:
pull_request:
push:
paths-ignore:
- 'README.md'
jobs:
build:
defaults:
run:
shell: sh
strategy:
fail-fast: true
matrix:
os:
#- macos-latest
- ubuntu-20.04
ocaml-version:
#- 4.11.0
- 4.10.1
#- 4.09.1
#- 4.08.1
runs-on: ${{ matrix.os }}
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- run: sudo add-apt-repository ppa:beineri/opt-qt-5.15.2-focal
- run: sudo apt install qt515quickcontrols2 libgl-dev --no-install-recommends --yes
#- run: . ./qt515-env.sh
- name: Use OCaml ${{ matrix.ocaml-version }}
uses: avsm/setup-ocaml@v2
with:
ocaml-compiler: ${{ matrix.ocaml-version }}
dune-cache: true
- name: Retrieve date for cache key
id: cache-key
run: echo "::set-output name=date::$(/bin/date -u "+%Y%m%d")"
shell: bash
- name: Restore opam cache
id: opam-cache
uses: actions/cache@v2
with:
path: "~/.opam"
# invalidate cache daily, gets built daily using a scheduled job
key: ${{ steps.cache-key.outputs.date }}
- run: sh -c '. ./qt515-env.sh && opam pin add conf-qt.dev . --no-action'
- run: sh -c '. ./qt515-env.sh && opam depext conf-qt.dev --yes'
- run: sh -c '. ./qt515-env.sh && opam install conf-qt.dev --yes'
- run: sh -c '. ./qt515-env.sh && opam pin add lablqml.dev . --no-action'
- run: sh -c '. ./qt515-env.sh && opam depext lablqml.dev --yes --with-doc --with-test'
- run: sh -c '. ./qt515-env.sh && opam install . --deps-only --with-doc --with-test'
- name: Building lablqml
run: sh -c '. ./qt515-env.sh && opam exec -- dune build -p lablqml'
- name: Testing lablqml
run: sh -c '. ./qt515-env.sh && opam exec -- dune runtest -p lablqml'
- name: Building lablqml demos
run: sh -c '. ./qt515-env.sh && opam exec -- dune build -p lablqml,lablqmlDemos'
- name: Testing lablqml demos
run: sh -c '. ./qt515-env.sh && opam exec -- dune runtest -p lablqml,lablqmlDemos'