mirror of
https://github.com/wez/wezterm.git
synced 2024-12-24 05:42:03 +03:00
58 lines
1.8 KiB
YAML
58 lines
1.8 KiB
YAML
name: verify-pages
|
|
|
|
on:
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- "docs/**"
|
|
- "ci/build-docs.sh"
|
|
- "ci/generate-docs.py"
|
|
- "ci/subst-release-info.py"
|
|
- ".github/workflows/verify-pages.yml"
|
|
- ".github/ISSUE_TEMPLATE/*"
|
|
|
|
jobs:
|
|
build-docs:
|
|
env:
|
|
BUILD_REASON: "PR"
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
- name: Install Rust
|
|
run: |
|
|
curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain stable
|
|
source $HOME/.cargo/env
|
|
rustup update stable
|
|
- uses: actions/cache@v3
|
|
name: Cache mdbook
|
|
with:
|
|
path: |
|
|
~/.cargo/bin/
|
|
~/.cargo/registry/index/
|
|
~/.cargo/registry/cache/
|
|
~/.cargo/git/db/
|
|
key: ${{ runner.os }}-cargo-mdbook-${{ hashFiles('.github/workflows/verify-pages.yml') }}
|
|
- name: Install mdBook
|
|
run: |
|
|
(test -x ~/.cargo/bin/mdbook || (cd && cargo install mdbook --no-default-features --features search --vers "^0.4" --locked))
|
|
- name: Install mdBook linkcheck
|
|
run: |
|
|
(test -x ~/.cargo/bin/mdbook-linkcheck || (cd && cargo install mdbook-linkcheck --locked))
|
|
- name: Install mdBook mermaid
|
|
run: |
|
|
(test -x ~/.cargo/bin/mdbook-mermaid || (cd && cargo install mdbook-mermaid --locked))
|
|
- name: Install mdBook admonish
|
|
run: |
|
|
(test -x ~/.cargo/bin/mdbook-admonish || (cd && cargo install mdbook-admonish --locked))
|
|
- name: Install gelatyx
|
|
run: |
|
|
(test -x ~/.cargo/bin/gelatyx || (cd && cargo install gelatyx --version "^0.2" --locked))
|
|
- name: Build
|
|
run: |
|
|
source $HOME/.cargo/env
|
|
PATH="$HOME/mdbook-bin:$PATH"
|
|
./ci/build-docs.sh
|
|
|