-
Notifications
You must be signed in to change notification settings - Fork 16
53 lines (44 loc) · 1.57 KB
/
publish-async-api-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
53
name: Publish Async API Documents
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
on:
workflow_dispatch:
inputs:
wasmedge_version:
description: "Version of WasmEdge"
required: true
type: string
jobs:
release_wasmedge_sdk:
name: Release wasmedge-sdk crate
runs-on: ubuntu-22.04
container:
image: wasmedge/wasmedge:ubuntu-build-clang
steps:
- name: Checkout WasmEdge Rust SDK
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up build environment
run: |
apt update
apt install -y software-properties-common libboost-all-dev ninja-build
apt install -y llvm-15-dev liblld-15-dev
- name: Install WasmEdge
run: |
curl -sSf https://raw.githubusercontent.com/WasmEdge/WasmEdge/master/utils/install.sh | bash -s -- -v ${{ inputs.wasmedge_version }} -p /usr/local
ldconfig
- name: Install Rust-stable
uses: dtolnay/rust-toolchain@stable
- name: Build Async API document
run: |
RUSTDOCFLAGS="--cfg docsrs" cargo doc -p wasmedge-sdk --workspace --no-deps --features aot,async,wasi_crypto,wasi_nn,wasmedge_process,ffi --target-dir=./target
- name: Deploy Async API document
if: github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_branch: gh-pages
publish_dir: target/doc
force_orphan: true