Skip to content

Commit

Permalink
Update docs.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
sanity authored Oct 21, 2023
1 parent 6744079 commit d82ac87
Showing 1 changed file with 1 addition and 25 deletions.
26 changes: 1 addition & 25 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,50 +14,26 @@ jobs:
with:
fetch-depth: 0
submodules: true

- name: Setup Rust
uses: ATiltedTree/setup-rust@v1
with:
rust-version: stable

- name: Cache Dependencies
uses: actions/cache@v3
with:
path: ~/.cargo
key: cargo-cache-${{ hashFiles('Cargo.lock') }}

- name: Install dependencies
run: |
cargo install mdbook mdbook-mermaid mdbook-toc
- name: Build MDBook for HEAD
- name: Build MDBook
run: |
if [ -d "docs" ]; then
cd docs
mdbook build
else
echo "Docs folder not found."
fi
- name: Checkout latest release
id: latest_release
run: |
LATEST_TAG=$(git describe --tags --abbrev=0)
echo "::set-output name=tag::${LATEST_TAG}"
git checkout $LATEST_TAG
- name: Create release subdirectory
run: mkdir -p docs/release

- name: Build MDBook for release
run: |
if [ -d "docs" ]; then
cd docs
mdbook build -d release
else
echo "Docs folder not found."
fi
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
Expand Down

0 comments on commit d82ac87

Please sign in to comment.