-
Notifications
You must be signed in to change notification settings - Fork 6
37 lines (33 loc) · 1.12 KB
/
deploy-doc.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
name: Preface deploy documentation
on:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Build
uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: 4.14.x
opam-depext-flags: --with-doc
- run: opam install . --deps-only --with-doc --with-test
- run: opam exec -- dune build
- run: opam exec -- dune build @doc
- run: mkdir -p _build/default/_doc/_html/images
- run: sudo apt-get install graphviz
- run: mkdir -p .github/figures
- run: dot -Tsvg .github/dot/specs.dot -o ./.github/figures/specs.svg
- run: dot -Tsvg .github/dot/cut.dot -o ./.github/figures/cut.svg
- run: cp .github/figures/* _build/default/_doc/_html/images
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
publish_dir: ./_build/default/_doc/_html/
external_repository: ocaml-preface/ocaml-preface.github.io
publish_branch: master
enable_jekyll: false