mirror of
https://github.com/adoyle0/leptos-use.git
synced 2025-01-23 09:09:21 -05:00
48 lines
1.1 KiB
YAML
48 lines
1.1 KiB
YAML
on:
|
|
workflow_dispatch:
|
|
|
|
name: Book
|
|
|
|
permissions:
|
|
contents: read
|
|
pages: write
|
|
id-token: write
|
|
|
|
jobs:
|
|
publish:
|
|
name: Publish
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: nightly
|
|
profile: minimal
|
|
override: true
|
|
components: rust-src
|
|
- name: Cache
|
|
uses: Swatinem/rust-cache@v2
|
|
- name: Install mdbook I
|
|
uses: taiki-e/install-action@v2
|
|
with:
|
|
tool: cargo-binstall,mdbook
|
|
- name: Install mdbook II
|
|
run: |
|
|
cargo binstall -y mdbook-cmdrun
|
|
cargo binstall -y trunk
|
|
rustup target add wasm32-unknown-unknown
|
|
- name: Setup Pages
|
|
id: pages
|
|
uses: actions/configure-pages@v3
|
|
- name: Build mdbook
|
|
run: |
|
|
cd docs/book
|
|
mdbook build
|
|
python3 post_build.py
|
|
- name: Upload artifact
|
|
uses: actions/upload-pages-artifact@v1
|
|
with:
|
|
path: ./docs/book/book
|
|
- name: Deploy book to github pages
|
|
id: deployment
|
|
uses: actions/deploy-pages@v2
|