mirror of
https://github.com/c-cube/nanoev.git
synced 2025-12-06 03:05:32 -05:00
add CI
This commit is contained in:
parent
15b39c3541
commit
dfee834611
2 changed files with 93 additions and 0 deletions
35
.github/workflows/gh-pages.yml
vendored
Normal file
35
.github/workflows/gh-pages.yml
vendored
Normal file
|
|
@ -0,0 +1,35 @@
|
||||||
|
name: github pages
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main # Set a branch name to trigger deployment
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
name: Deploy doc
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@main
|
||||||
|
|
||||||
|
- name: Use OCaml
|
||||||
|
uses: ocaml/setup-ocaml@v3
|
||||||
|
with:
|
||||||
|
ocaml-compiler: '5.2'
|
||||||
|
dune-cache: true
|
||||||
|
allow-prerelease-opam: true
|
||||||
|
|
||||||
|
# temporary until it's in a release
|
||||||
|
- run: opam pin picos 0.6.0 -y -n
|
||||||
|
|
||||||
|
- run: opam install picos moonpool trace
|
||||||
|
|
||||||
|
- run: opam exec -- odig odoc --cache-dir=_doc/ nanoev
|
||||||
|
|
||||||
|
- name: Deploy
|
||||||
|
uses: peaceiris/actions-gh-pages@v3
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
publish_dir: ./_doc/html
|
||||||
|
destination_dir: .
|
||||||
|
enable_jekyll: false
|
||||||
58
.github/workflows/main.yml
vendored
Normal file
58
.github/workflows/main.yml
vendored
Normal file
|
|
@ -0,0 +1,58 @@
|
||||||
|
name: Build and Test
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
run:
|
||||||
|
name: build # build+test on various versions of OCaml, on linux
|
||||||
|
timeout-minutes: 15
|
||||||
|
strategy:
|
||||||
|
fail-fast: true
|
||||||
|
matrix:
|
||||||
|
os:
|
||||||
|
- ubuntu-latest
|
||||||
|
ocaml-compiler:
|
||||||
|
- '5.0'
|
||||||
|
- '5.3'
|
||||||
|
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@main
|
||||||
|
- name: Use OCaml ${{ matrix.ocaml-compiler }}
|
||||||
|
uses: ocaml/setup-ocaml@v3
|
||||||
|
with:
|
||||||
|
ocaml-compiler: ${{ matrix.ocaml-compiler }}
|
||||||
|
dune-cache: true
|
||||||
|
allow-prerelease-opam: true
|
||||||
|
|
||||||
|
- run: opam exec -- dune build @install
|
||||||
|
|
||||||
|
# install some depopts
|
||||||
|
- run: opam pin picos 0.6.0 -y -n
|
||||||
|
- run: opam install -t moonpool trace picos
|
||||||
|
|
||||||
|
- run: opam exec -- dune build --profile=release --force @install @runtest
|
||||||
|
|
||||||
|
format:
|
||||||
|
name: format
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
ocaml-compiler:
|
||||||
|
- '5.2'
|
||||||
|
runs-on: 'ubuntu-latest'
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@main
|
||||||
|
- name: Use OCaml ${{ matrix.ocaml-compiler }}
|
||||||
|
uses: ocaml/setup-ocaml@v3
|
||||||
|
with:
|
||||||
|
ocaml-compiler: ${{ matrix.ocaml-compiler }}
|
||||||
|
dune-cache: true
|
||||||
|
allow-prerelease-opam: true
|
||||||
|
|
||||||
|
- run: opam install ocamlformat.0.26.2
|
||||||
|
- run: opam exec -- make format-check
|
||||||
|
|
||||||
Loading…
Add table
Reference in a new issue