-
Notifications
You must be signed in to change notification settings - Fork 14
42 lines (42 loc) Β· 1.55 KB
/
reusable-docs.yml
File metadata and controls
42 lines (42 loc) Β· 1.55 KB
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
name: π Build and Deploy Docs
on:
workflow_call:
permissions:
contents: write
pull-requests: write
jobs:
build-and-deploy:
concurrency: ci-${{ github.ref }}
runs-on: ubuntu-latest
steps:
- name: Checkout ποΈ
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Install Doxygen
if: github.event.action != 'closed'
uses: ssciwr/doxygen-install@329d88f5a303066a5bd006db7516b1925b86350e # v2.0.1
with:
version: "1.15.0"
- name: Install and Build π§
if: github.event.action != 'closed'
run: |
cmake -S . -B build -DBUILD_QDMI_DOCS=ON
cmake --build build --target qdmi_docs
mv build/docs/html/ static
- name: Inject version selector
if: github.event.action != 'closed'
run: |
chmod +x .github/scripts/inject-version-selector.sh
.github/scripts/inject-version-selector.sh static
- name: Deploy preview π (for PRs; not for forks)
if: github.event.pull_request.head.repo.full_name == github.repository
uses: rossjrw/pr-preview-action@ffa7509e91a3ec8dfc2e5536c4d5c1acdf7a6de9 # v1.8.1
with:
source-dir: ./static/
- name: Deploy π
if: github.ref == 'refs/heads/develop' && github.event.action != 'closed'
uses: JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # v4.8.0
with:
folder: static
target-folder: latest
clean-exclude: pr-preview/
force: false