Skip to content

Commit 61f5c39

Browse files
committed
[CI] add github action
1 parent 14e634e commit 61f5c39

File tree

2 files changed

+36
-0
lines changed

2 files changed

+36
-0
lines changed

.github/workflows/build.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: build
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
check:
7+
name: build
8+
runs-on: ubuntu-20.04
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v2
12+
13+
- name: Set up OCaml
14+
uses: ocaml/setup-ocaml@v2
15+
with:
16+
ocaml-compiler: 4.13.1
17+
18+
- name: Use cached dependencies
19+
id: cache-opam
20+
uses: actions/cache@v3
21+
env:
22+
cache-name: cache-opam
23+
with:
24+
path: |
25+
~/.opam
26+
./_opam
27+
key: ${{ env.cache-name }}-build-${{ hashFiles('opam', 'build.sh') }}
28+
restore-keys: |
29+
${{ env.cache-name }}-build-${{ hashFiles('opam', 'build.sh') }}
30+
${{ env.cache-name }}-build-
31+
32+
- name: Build CIL
33+
run: |
34+
./build.sh || eval $(opam env) && make

build.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
opam pin add prosys-cil . -y
2+
make

0 commit comments

Comments
 (0)