-
Notifications
You must be signed in to change notification settings - Fork 112
40 lines (35 loc) · 1.23 KB
/
build_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
38
39
40
name: Build docs
on:
push:
branches: [ main ]
# pull_request:
# branches: [ main ]
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: Setup mdbook
run: wget https://github.com/rust-lang/mdBook/releases/download/v0.4.25/mdbook-v0.4.25-x86_64-unknown-linux-musl.tar.gz && tar -xvzf mdbook-v0.4.25-x86_64-unknown-linux-musl.tar.gz && rm ./mdbook-v0.4.25-x86_64-unknown-linux-musl.tar.gz
- name: Build MONA_DSL docs
run: ./mdbook build mona_dsl_book
- name: Build main site docs
run: ./mdbook build mona_book
- name: Build core docs
run: cargo doc --manifest-path mona_core/Cargo.toml --no-deps --document-private-items --lib
- name: Create a big dir
run: mkdir dist_docs_no_ignore
- name: Copy docs
run: cp -R mona_dsl_book/book dist_docs_no_ignore/dsl && cp -R mona_book/book dist_docs_no_ignore/main && cp -R mona_core/target/doc dist_docs_no_ignore/mona_core
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: docs
path: dist_docs_no_ignore