-
Notifications
You must be signed in to change notification settings - Fork 2
52 lines (51 loc) · 1.36 KB
/
docs.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
name: Docs
on:
workflow_run:
workflows: ["CI"]
types:
- completed
permissions:
contents: write
pages: write
id-token: write
concurrency:
group: deploy
cancel-in-progress: false
jobs:
build:
name: Build Documentation
timeout-minutes: 15
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Checkout submodules
run: git submodule update --init --recursive
- name: Install Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- name: Clean docs folder
run: |
sudo apt-get update && sudo apt-get install -y uuid-dev
cargo clean --doc
cargo doc --workspace --no-deps
- name: Add redirect
run: echo '<meta http-equiv="refresh" content="0;url=rusteron_archive/index.html">' > target/doc/index.html
- name: Remove lock file
run: rm target/doc/.lock
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: target/doc
deploy:
name: Deploy to GitHub Pages
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4